GlobalChem DNA

GlobalChem has the concept of a DNA into a 1-Dimensional format that can be used later on for dna-smiles to dna-ligand interaction of lexical strings. This way we can perhaps make casual inference between sets of ligands and sets of dna or proteins later on.

Import the Package

from global_chem_extensions import GlobalChemExtensions
bioinformatics = GlobalChemExtensions().bioinformatics()

Initialize a DNA Object

dna_molecule = bioinformatics.initialize_globalchem_dna(
        peptide_sequence='TGGGGAGGGTG',
)

Convert to SMILES

dna_molecule.convert_to_smiles()

Convert to SMARTS

dna_molecule.convert_to_smarts()

Visualize the DNA Strand

dna_molecule.visualize_strand()

Visualize and Label the DNA Strand

dna_molecule.label_feature(
    start=0,
    end=3,
    label='Start'
)

dna_molecule.label_feature(
    start=4,
    end=8,
    label='Middle'
)


dna_molecule.label_feature(
    start=4,
    end=8,
    label='Middle 2',
    color='Blue'
)

dna_molecule.label_feature(
    start=8,
    end=12,
    label='End',
    color='Green'
)

dna_molecule.visualize_strand()

Save the DNA Image to a file

dna.save_to_image() 

Last updated