Mercurial > repos > proteore > proteore_prot_features
changeset 18:bdbc7620e804 draft
"planemo upload commit 6a3a63d9870148e6fee84e771db614f9da9a8245"
| author | proteore |
|---|---|
| date | Thu, 30 Jul 2020 09:25:25 +0000 |
| parents | 3c5fafe2f338 |
| children | 381e18f13ed2 |
| files | add_protein_features.R add_protein_features.xml |
| diffstat | 2 files changed, 33 insertions(+), 46 deletions(-) [+] |
line wrap: on
line diff
--- a/add_protein_features.R Thu Jun 27 09:36:34 2019 -0400 +++ b/add_protein_features.R Thu Jul 30 09:25:25 2020 +0000 @@ -48,9 +48,7 @@ --column: the column number which you would like to apply... --header: true/false if your file contains a header --type: the type of input IDs (Uniprot_AC/EntrezID) - --pc_features: IsoPoint,SeqLength,MW - --localization: Chr,SubcellLocations - --diseases_info: Diseases + --pc_features: IsoPoint,SeqLength,MW,Chr,SubcellLocations,Diseases,protein_name,function,post_trans_mod,protein_family,pathway --output: text output filename \n") q(save="no") @@ -122,12 +120,7 @@ # Get information from neXtProt get_nextprot_info <- function(nextprot,input,pc_features,localization,diseases_info){ - if(diseases_info){ - cols = c("NextprotID",pc_features,localization,"Diseases") - } else { - cols = c("NextprotID",pc_features,localization) - } - + cols = c("NextprotID",pc_features) cols=cols[cols!="None"] info = nextprot[match(input,nextprot$NextprotID),cols] return(info) @@ -172,8 +165,6 @@ # Parse arguments id_type = args$type pc_features = strsplit(args$pc_features, ",")[[1]] - localization = strsplit(args$localization, ",")[[1]] - diseases_info = str2bool(args$diseases_info) output = args$output # Change the sample ids if they are Uniprot_AC ids to be able to match them with @@ -191,7 +182,7 @@ if (all(!NextprotID %in% nextprot[,1])){ write.table("None of the input ids can be found in Nextprot",file=output,sep="\t",quote=FALSE,col.names=TRUE,row.names=FALSE) } else { - res <- get_nextprot_info(nextprot,NextprotID,pc_features,localization,diseases_info) + res <- get_nextprot_info(nextprot,NextprotID,pc_features) res = res[!duplicated(res$NextprotID),] output_content = merge(file, res,by.x=ncol,by.y="NextprotID",incomparables = NA,all.x=T) output_content = order_columns(output_content,ncol,id_type,file)
--- a/add_protein_features.xml Thu Jun 27 09:36:34 2019 -0400 +++ b/add_protein_features.xml Thu Jul 30 09:25:25 2020 +0000 @@ -1,5 +1,5 @@ -<tool id="prot_features" name="Add protein features" version="2019.06.27.2"> -<description>[neXtProt] +<tool id="prot_features" name="Add protein features" version="2020.07.30"> +<description>[neXtProt, Human] </description> <requirements> <requirement type="package" version="3.4.1">R</requirement> @@ -19,9 +19,7 @@ #end if --type='$idtype' - --pc_features='$Nextprot_params.pc_features' - --localization='$Nextprot_params.localization' - --diseases_info='$Nextprot_params.diseases_info' + --pc_features='$pc_features' --output='$output' #if 'proteore_nextprot_ref' in str($ref_file).split("/") @@ -34,7 +32,7 @@ <inputs> <conditional name="inputtype"> - <param name="filetype" type="select" label="Enter your IDs (neXtProt or UniProt; e.g. P05090 or NX_P05090)" help="Copy/paste or from a file" > + <param name="filetype" type="select" label="Enter your IDs (neXtProt or UniProt; e.g. NX_P05090 or P05090)" help="Copy/paste or from a file" > <option value="file" selected="true">Input file containing your IDs </option> <option value="copy_paste">Copy/paste your list of IDs</option> </param> @@ -63,32 +61,31 @@ </when> </conditional> - <param name="idtype" type="select" label="Type of IDs" multiple="false" optional="false"> - <option value="NextprotID" selected="true">neXtProt IDs</option> - <option value="Uniprot_AC" selected="false">UniProt accession number</option> - </param> - <section name="Nextprot_params" title="Select features (Physico-chemical, localization, disease infiormation)" expanded="True"> - <param name="pc_features" type="select" label="Select information to add to your list" multiple="true" help="" display="checkboxes" optional="false"> - <option value="SeqLength" selected="false">Sequence Length</option> - <option value="MW" selected="false">Molecular Weight</option> - <option value="IsoPoint" selected="false">Isoelectric point</option> - <option value="TMDomains" selected="false">Number of transmembrane domains</option> - <option value="ProteinExistence" selected="false">Protein Existence (evidence score from 1 to 5)</option> - </param> + <param name="idtype" type="select" label="Type of IDs" multiple="false" optional="false"> + <option value="NextprotID" selected="true">neXtProt IDs</option> + <option value="Uniprot_AC" selected="false">UniProt accession number</option> + </param> + <param name="pc_features" type="select" label="Features/Annotation" multiple="true" help="" display="checkboxes" optional="false"> + <option value="SeqLength" selected="false">Sequence Length</option> + <option value="MW" selected="false">Molecular Weight</option> + <option value="IsoPoint" selected="false">Isoelectric point</option> + <option value="TMDomains" selected="false">Number of transmembrane domains</option> + <option value="ProteinExistence" selected="false">Protein Existence (evidence score from 1 to 5)</option> + <option value="Chr" selected="false">Chromosome</option> + <option value="SubcellLocations" selected="false">Subcellular Location</option> + <option value="Diseases" selected="false">Disease information</option> + <option value="ProteinName" selected="false">Protein name</option> + <option value="Function" selected="false">Protein function</option> + <option value="PostTranslationalModifications" selected="false">Post translational modifications</option> + <option value="ProteinFamily" selected="false">Protein family</option> + <option value="Pathway" selected="false">Pathway(s)</option> + </param> - <param name="localization" type="select" label="Localization" multiple="true" help="" display="checkboxes" optional="true"> - <option value="Chr" selected="false">Chromosome</option> - <option value="SubcellLocations" selected="false">Subcellular Location</option> - </param> - - <param name="diseases_info" type="boolean" checked="true" truevalue="true" falsevalue="false" label="Disease information" /> - - </section> - <param name="ref_file" type="select" label="Release of neXtProt reference file to use"> + <param name="ref_file" type="select" label="Release of neXtProt reference file to use"> <options from_data_table="proteore_nextprot_ref"> <filter type="sort_by" column="0"/> </options> - </param> + </param> </inputs> @@ -110,12 +107,7 @@ </conditional> <param name="idtype" value="Uniprot_AC"/> - - <section name="Nextprot_params"> - <param name="pc_features" value="SeqLength,MW,IsoPoint,TMDomains,ProteinExistence"/> - <param name="localization" value="Chr,SubcellLocations"/> - <param name="diseases_info" value="true"/> - </section> + <param name="pc_features" value="SeqLength,MW,IsoPoint,TMDomains,ProteinExistence"/> <param name="ref_file" value="test-data/cached_locally/nextprot_ref_07-05-2019.tsv"/> <output name="output" file="Add_information_from_neXtProt.tsv"/> @@ -161,6 +153,10 @@ - nextProt release 07-05-2019 (release Feb 13, 2019) - neXtProt release 08-10-2018 (release Feb 21, 2018) +.. class:: warningmark + +For "Protein function", "Post translational modifications" and "Pathway(s)", only results with gold quality are returned. + ----- .. class:: infomark
