This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Primer design scripts. OSError: Missing SEQUENCE tag

I made primer design script. when I input the sequence, there are error. how can i solve this problem. i attached error code and my script.

please give me a solution. Thank you very much.

File "Primer_short.py", line 26, in <module> 'SEQUENCE_TEMPLATE': raw_sequence File "/home/youngho/anaconda3/lib/python3.7/site-packages/primer3/bindings.py", line 276, in designPrimers return primerdesign.runDesign(debug) OSError: Missing SEQUENCE tag

import primer3
import pandas as pd

# Get raw sequence input
raw_sequence = input("Enter the raw sequence: ")

# Global parameters
global_args = {
    'PRIMER_TASK': 'generic',
    'PRIMER_MIN_SIZE': 18,
    'PRIMER_MAX_SIZE': 25,
    'PRIMER_OPT_SIZE': 20,
    'PRIMER_MIN_TM': 57,
    'PRIMER_OPT_TM': 60,
    'PRIMER_MAX_TM': 63,
    'PRIMER_MIN_GC': 20,
    'PRIMER_MAX_GC': 80,
    'PRIMER_MAX_POLY_X': 5
}

# Use primer3 to design primers
primer_data = primer3.bindings.designPrimers(
    global_args,
    {
        'SEQUENCE_ID': 'example',
        'SEQUENCE_TEMPLATE': raw_sequence
    }
)

# Convert primer data to a pandas DataFrame
primer_df = pd.DataFrame(primer_data['PRIMER_PAIR_0'], index=[0])

# Print the primer DataFrame
print(primer_df)
oserror primer3
global_args,
    {
        'SEQUENCE_ID': 'example',
        'SEQUENCE_TEMPLATE': raw_sequence
    }

to

    {
            'SEQUENCE_ID': 'example',
            'SEQUENCE_TEMPLATE': raw_sequence
        }, 
global_args

0 answers

No answers yet.

Log in to answer this question.