04 September 2010

Dumping NCBI Gene as XML: my notebook.

Download the NCBI C toolbox

The version I used was ftp://ftp.ncbi.nih.gov/toolbox/ncbi_tools++/CURRENT/NCBI_C_Toolkit/ncbi_c--Jun_15_2010.tar.gz, the uncompress the file.
Change the name to 'ncbi':
mv ncbi_c--Jun_15_2010.tar.gz ncbi
and compile the toolkit:
ncbi/make/makedis.csh
(...)
*********************************************************
*The new binaries are located in ./ncbi/build/ directory*
*********************************************************

Download NCBI gene as ASN.1 for Homo Sapiens


Call gene2xml to transform NCBI gene as ASN.1 to XML


ncbi/build/gene2xml -b -i Homo_sapiens.ags
<?xml version="1.0"?>
<!DOCTYPE Entrezgene-Set PUBLIC "-//NCBI//NCBI Entrezgene/EN" "NCBI_Entrezgene.dtd">
<Entrezgene-Set>

<Entrezgene>
<Entrezgene_track-info>
<Gene-track>
<Gene-track_geneid>1</Gene-track_geneid>
<Gene-track_status value="live">0</Gene-track_status>

<Gene-track_create-date>
<Date>


That's it

Pierre

No comments: