Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tools/waveica/macros.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<macros>
<token name="@TOOL_VERSION@">0.2.0</token>
<token name="@TOOL_VERSION@">0.2.1</token>

<xml name="creator">
<creator>
Expand Down
Binary file modified tools/waveica/test-data/normalized_data.parquet
Binary file not shown.
Binary file modified tools/waveica/test-data/test3_output.parquet
Binary file not shown.
Binary file modified tools/waveica/test-data/test9_output1.parquet
Binary file not shown.
24 changes: 12 additions & 12 deletions tools/waveica/waveica.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

<requirements>
<requirement type="package" version="@TOOL_VERSION@">r-recetox-waveica</requirement>
<requirement type="package" version="8.0.0">r-arrow</requirement>
<requirement type="package" version="1.0.10">r-dplyr</requirement>
<requirement type="package" version="24.0.0">r-arrow</requirement>
<requirement type="package" version="1.2.1">r-dplyr</requirement>
</requirements>
<command detect_errors="aggressive"><![CDATA[
Rscript -e "source('${__tool_directory__}/waveica_wrapper.R');
Expand All @@ -23,8 +23,8 @@
wavelet_filter = '$wf.wavelet_filter',
wavelet_length = '$wf.wavelet_length',
k = $k,
t = $batch_correction.t,
t2 = $batch_correction.t2,
batch_threshold = $batch_correction.batch_threshold,
group_threshold = $batch_correction.group_threshold,
alpha = $alpha,
exclude_blanks = $exclude_blanks,
transpose = $transpose_feature_table
Expand Down Expand Up @@ -63,8 +63,8 @@
<option value="single_batch">Single batch (or no batch information)</option>
</param>
<when value="batchwise">
<param type="float" value="0.05" name="t" label="Batch-association threshold" help="threshold to consider a component associate with the batch, should be between 0 and 1"/>
<param type="float" value="0.05" name="t2" label="Group-association threshold" help="threshold to consider a component associate with the group, should be between 0 and 1"/>
<param type="float" value="0.05" name="batch_threshold" label="Batch-association threshold" help="threshold to consider a component associate with the batch, should be between 0 and 1"/>
<param type="float" value="0.05" name="group_threshold" label="Group-association threshold" help="threshold to consider a component associate with the group, should be between 0 and 1"/>
</when>
<when value="single_batch">
<param type="float" value="0" name="cutoff" label="Cutoff" help="threshold of the variation explained by the injection order for independent components, should be between 0 and 1"/>
Expand All @@ -87,8 +87,8 @@
</conditional>
<conditional name="batch_correction">
<param name="mode" value="batchwise"/>
<param name="t" value="0.05"/>
<param name="t2" value="0.05"/>
<param name="batch_threshold" value="0.05"/>
<param name="group_threshold" value="0.05"/>
</conditional>
<output name="normalized_data" file="test1_output.csv" ftype="csv"/>
</test>
Expand All @@ -103,8 +103,8 @@
</conditional>
<conditional name="batch_correction">
<param name="mode" value="batchwise"/>
<param name="t" value="0.05"/>
<param name="t2" value="0.05"/>
<param name="batch_threshold" value="0.05"/>
<param name="group_threshold" value="0.05"/>
</conditional>
<output name="normalized_data" file="normalized_data.tsv" ftype="tabular"/>
</test>
Expand All @@ -119,8 +119,8 @@
</conditional>
<conditional name="batch_correction">
<param name="mode" value="batchwise"/>
<param name="t" value="0.05"/>
<param name="t2" value="0.05"/>
<param name="batch_threshold" value="0.05"/>
<param name="group_threshold" value="0.05"/>
</conditional>
<output name="normalized_data" file="test3_output.parquet" compare="sim_size" delta="200" ftype="parquet"/>
</test>
Expand Down
10 changes: 5 additions & 5 deletions tools/waveica/waveica_wrapper.R
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ waveica <- function(data_matrix_file,
wavelet_filter,
wavelet_length,
k,
t,
t2,
batch_threshold,
group_threshold,
alpha,
exclude_blanks,
transpose = FALSE) {
Expand All @@ -75,7 +75,7 @@ waveica <- function(data_matrix_file,
"injectionOrder", "batch"
)

metadata <- dplyr::select(metadata, required_columns)
metadata <- dplyr::select(metadata, all_of(required_columns))

# Ensure both tables have a sampleName column
if (!"sampleName" %in% colnames(features) || !"sampleName" %in% colnames(metadata)) { # nolint
Expand Down Expand Up @@ -113,8 +113,8 @@ waveica <- function(data_matrix_file,
batch = batch,
group = group,
K = k,
t = t,
t2 = t2,
batch_threshold = batch_threshold,
group_threshold = group_threshold,
alpha = alpha
)
non_feature_columns <- setdiff(colnames(data), feature_columns)
Expand Down