From b30bf15d38bc9213775dcab41a56274c8da0de15 Mon Sep 17 00:00:00 2001 From: stevereis <stevereis93@gmail.com> Date: Tue, 2 Nov 2021 18:17:46 +0100 Subject: [PATCH] Fix descriptive stats input data format --- api/src/engine/connectors/exareme/converters.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/api/src/engine/connectors/exareme/converters.ts b/api/src/engine/connectors/exareme/converters.ts index ab84084..1e43bfb 100644 --- a/api/src/engine/connectors/exareme/converters.ts +++ b/api/src/engine/connectors/exareme/converters.ts @@ -59,28 +59,33 @@ export const dataToVariable = (data: VariableEntity): Variable => { const algoParamInputToData = (param: AlgorithmParameter) => { return { name: param.name, + label: param.name, value: param.value.join(','), }; }; export const experimentInputToData = (data: ExperimentCreateInput) => { - return { + const params = { algorithm: { parameters: [ { name: 'dataset', + label: 'dataset', value: data.datasets.join(','), }, { name: 'filter', + label: 'filter', value: data.filter, }, { name: 'pathology', + label: 'pathology', value: data.domain, }, { name: 'y', + label: 'y', value: data.variables.join(','), }, ].concat(data.algorithm.parameters.map(algoParamInputToData)), @@ -89,6 +94,8 @@ export const experimentInputToData = (data: ExperimentCreateInput) => { }, name: data.name, }; + + return params; }; export const descriptiveDataToTableResult = ( -- GitLab