Skip to content

Commit 16309ff

Browse files
committed
Support inclusion/exclusion lists for ApplyKnownClonotypicData
1 parent e6146f0 commit 16309ff

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

singlecell/resources/chunks/ApplyKnownClonotypicData.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ for (datasetId in names(seuratObjects)) {
1111
printName(datasetId)
1212
seuratObj <- readSeuratRDS(seuratObjects[[datasetId]])
1313

14-
seuratObj <- ApplyKnownClonotypicData(seuratObj)
14+
seuratObj <- ApplyKnownClonotypicData(seuratObj, antigenInclusionList = antigenInclusionList, antigenExclusionList = antigenExclusionList)
1515
saveData(seuratObj, datasetId)
1616

1717
# Cleanup

singlecell/src/org/labkey/singlecell/pipeline/singlecell/ApplyKnownClonotypicData.java

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
package org.labkey.singlecell.pipeline.singlecell;
22

3+
import org.json.JSONObject;
34
import org.labkey.api.sequenceanalysis.pipeline.AbstractPipelineStepProvider;
45
import org.labkey.api.sequenceanalysis.pipeline.PipelineContext;
6+
import org.labkey.api.singlecell.pipeline.SeuratToolParameter;
57
import org.labkey.api.singlecell.pipeline.SingleCellStep;
68

79
import java.util.List;
@@ -18,8 +20,21 @@ public static class Provider extends AbstractPipelineStepProvider<SingleCellStep
1820
public Provider()
1921
{
2022
super("ApplyKnownClonotypicData", "Append Known Clonotype/Antigen Data", "RDiscvr", "This will query the clone_responses table and append a column tagging each cell for matching antigens (based on clonotype)", List.of(
21-
22-
), null, null);
23+
SeuratToolParameter.create("antigenInclusionList", "Antigen(s) to Include", "Enter antigens, per line. Only stims using these antigens will be used", "sequenceanalysis-trimmingtextarea", new JSONObject()
24+
{{
25+
put("allowBlank", false);
26+
put("height", 150);
27+
put("delimiter", ",");
28+
put("stripCharsRe", "/['\"]/g");
29+
}}, null, null, true, true).delimiter(","),
30+
SeuratToolParameter.create("antigenExclusionList", "Antigen(s) to Exclude", "Enter antigens, per line. Stims using these antigens will be excluded", "sequenceanalysis-trimmingtextarea", new JSONObject()
31+
{{
32+
put("allowBlank", false);
33+
put("height", 150);
34+
put("delimiter", ",");
35+
put("stripCharsRe", "/['\"]/g");
36+
}}, null, null, true, true).delimiter(",")
37+
), List.of("/sequenceanalysis/field/TrimmingTextArea.js"), null);
2338
}
2439

2540

0 commit comments

Comments
 (0)