Package: ddipy
ddipyAnPython packageto obtain data from the Omics Discovery Index (OmicsDI. It uses the RESTful Web Services atOmicsDI WSfor that purpose.Installationwe need to installddipy:pip install ddipyExamplesThis example shows how retrieve details of one dataset by using the Python package ddipy.fromddipy.dataset_clientimportDatasetClientif__name__=='__main__':client=DatasetClient()res=client.get_dataset_details("pride","PXD000210",False)This example shows a search for all the datasets for human.fromddipy.dataset_clientimportDatasetClientif__name__=='__main__':client=DatasetClient()res=client.search("cancer human","publication_date","ascending")This example shows a search for all the datasets for cancer human and loop over the paginationfromddipy.dataset_clientimportDatasetClientif__name__=='__main__':client=DatasetClient()res=client.search("cancer human","publication_date","ascending",1200,30,20)This example is a query to retrieve all the datasets that reported the UniProt protein P21399 as identified.fromddipy.dataset_clientimportDatasetClientif__name__=='__main__':client=DatasetClient()res=client.search("UNIPROT:P21399")This example is a query to find all the datasets where the gene ENSG00000147251 is reported as differentially expressed.fromddipy.dataset_clientimportDatasetClientif__name__=='__main__':client=DatasetClient()res=client.search("ENSEMBL:ENSG00000147251")This example is a query to retrieve all databases recorded in OmicsDIfromddipy.dataset_clientimportDatabaseClientif__name__=='__main__':client=DatabaseClient()res=client.get_database_all()This example is retrieving JSON+LD for dataset pagefromddipy.dataset_clientimportSeoClientif__name__=='__main__':client=SeoClient()res=client.get_seo_dataset("pride","PXD000210")This example is  retriveing JSON+LD for home pagefromddipy.dataset_clientimportSeoClientif__name__=='__main__':client=SeoClient()res=client.get_seo_home()This example is a query for statistics about the number of datasets per Tissuefromddipy.dataset_clientimportStatisticsClientif__name__=='__main__':client=StatisticsClient()res=client.get_statistics_tissues(20)This example is a query for statistics about the number of datasets per dieasesfromddipy.dataset_clientimportStatisticsClientif__name__=='__main__':client=StatisticsClient()res=client.get_statistics_diseases(20)This example for searching dictionary termsfromddipy.dataset_clientimportTermClientif__name__=='__main__':client=TermClient()res=client.get_term_by_pattern("hom",10)This example for retrieving frequently terms from the repofromddipy.dataset_clientimportTermClientif__name__=='__main__':client=TermClient()res=client.get_term_by_pattern("pride","description",20)Find out about us in our GitHub profiles:Yasset Perez-RiverolPan XuCLI for downloading filesWhen ddipy is installed correctly it should be available on your path through the commandomicsdi. This command line interface makes it possible to list all the data links and download the data itself related to an accession number. The tool has one mandatory parameter 'accession number' and several options:omicsdi_fetcher [OPTIONS] ACC_NUMBEROptionTypeDescription--versionFLAGShow the version and exit.-d, --downloadFLAGUse this flag to download the files in the current directory or a specified output directory-v, --verboseFLAGUse this flag to print identifiers and file extension along with the urls-i, --inputLISTThis option allows you to download the a selection of the files based on comma separated list of identifiers-o, --outputPATHOutput directory when downloading files (default: CWD)-h, --helpFLAGShow this message and exit.ExamplesA microarray dataset with ftp links:omicsdi E-MTAB-5612Downloading the microarray dataset with ftp links:omicsdi E-MTAB-5612 -dA BioModels dataset with https links and exposing identifiers for each file link:omicsdi BIOMD0000000048 -vDownloading a selection of the files belonging to an accession number based on a list of identifiers as input:omicsdi BIOMD0000000048 -d -i "8b52492888, d3144265ac"