Skip to content
Snippets Groups Projects
Commit b9798355 authored by Gervaise Henry's avatar Gervaise Henry :cowboy:
Browse files

Convert strandedness from yes/no to t/f

parent 3b3b7891
Branches
Tags
2 merge requests!68Develop,!67Resolve "Change Single Read to Single End for submitted endness"
Pipeline #9103 failed with stages
in 28 minutes and 18 seconds
# v2.0.0 # v2.0.0
**User Facing** **User Facing**
* Endness metadata "Single Read" changed to "Single End" in data-hub, pipeline updated to handle (#110) ("Single Read" still acceptable for backwards compatibility) * Endness metadata "Single Read" changed to "Single End" in data-hub, pipeline updated to handle (#110) ("Single Read" still acceptable for backwards compatibility)
* Strandedness metadata "yes"/"no" changed to boolean "t"/"f" in data-hub, pipeline updated to handle (#70) ("yes"/"no" still acceptable for backwards compatibility)
**Background** **Background**
* Add memory limit (75%) per thread for samtools sort (#108) * Add memory limit (75%) per thread for samtools sort (#108)
......
...@@ -367,8 +367,27 @@ process parseMetadata { ...@@ -367,8 +367,27 @@ process parseMetadata {
echo -e "LOG: strandedness metadata parsed: \${stranded}" >> ${repRID}.parseMetadata.log echo -e "LOG: strandedness metadata parsed: \${stranded}" >> ${repRID}.parseMetadata.log
# get spike-in metadata # get spike-in metadata
spike=\$(python3 ${script_parseMeta} -r ${repRID} -m "${experimentSettings}" -p spike) v=\$(python3 ${script_parseMeta} -r ${repRID} -m "${experimentSettings}" -p spike)
echo -e "LOG: spike-in metadata parsed: \${spike}" >> ${repRID}.parseMetadata.log echo -e "LOG: spike-in metadata parsed: \${spike}" >> ${repRID}.parseMetadata.log
if [ "\${spike}" == "f" ]
then
spike="false"
elif [ "\${spike}" == "t" ]
then
spike="true"
elseif [ "\${spike}" == "no" ]
# "yes"/"no" depreciated as of Jan 2021, this option is present for backwards compatibility
then
spike="false"
elseif [ "\${spike}" == "yes" ]
# "yes"/"no" depreciated as of Jan 2021, this option is present for backwards compatibility
then
spike="true"
elif [ "\${spike}" == "nan" ]
then
endsRaw="_No value_"
endsMeta="NA"
fi
# get species metadata # get species metadata
species=\$(python3 ${script_parseMeta} -r ${repRID} -m "${experiment}" -p species) species=\$(python3 ${script_parseMeta} -r ${repRID} -m "${experiment}" -p species)
...@@ -935,9 +954,9 @@ process inferMetadata { ...@@ -935,9 +954,9 @@ process inferMetadata {
# determine spike-in # determine spike-in
if [ 1 -eq \$(echo \$(expr \${align_ercc} ">=" 10)) ] if [ 1 -eq \$(echo \$(expr \${align_ercc} ">=" 10)) ]
then then
spike="yes" spike="true"
else else
spike="no" spike="false"
fi fi
echo -e "LOG: inference of strandedness results is: \${spike}" >> ${repRID}.inferMetadata.log echo -e "LOG: inference of strandedness results is: \${spike}" >> ${repRID}.inferMetadata.log
......
...@@ -73,12 +73,7 @@ def main(): ...@@ -73,12 +73,7 @@ def main():
# Get spike-in metadata from 'Experiment Settings.csv' # Get spike-in metadata from 'Experiment Settings.csv'
if (args.parameter == "spike"): if (args.parameter == "spike"):
if (metaFile.Used_Spike_Ins.unique() == "yes"): spike = metaFile.Used_Spike_Ins.unique()[0]
spike = "yes"
elif (metaFile.Used_Spike_Ins.unique() == "no"):
spike = "no"
else:
spike = metaFile.Used_Spike_Ins.unique()[0]
print(spike) print(spike)
# Get species metadata from 'Experiment.csv' # Get species metadata from 'Experiment.csv'
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment