Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

grdi export one health enterics #441

Merged
merged 36 commits into from
Oct 22, 2024
Merged

Conversation

ivansg44
Copy link
Collaborator

No description provided.

@ivansg44 ivansg44 added the wip Work in progress label Aug 22, 2024
* return "";
* }
* ```
* TODO is there any need for additional complexities in getMappedField?
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ddooley I am just copy-pasting vals for the most part (with the exception of some trimming I also need advice on below)

);
const valsToCheck = headerNamesToCheck.map((headerName) => {
const valToCheck = inputRow[sourceFieldNameMap[headerName]];
// TODO trim because copy pasting from excel == '\r\n'; wider issue?
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -73,6 +73,7 @@ export default {
// ['gene_name_2', []],
// ['diagnostic_PCR_CT_value_2', []],
// ['description',[]],
// TODO there are additional fields now; what order?
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ddooley Does the existing biosample need to be updated too?

@@ -104,4 +105,397 @@ export default {
return outputMatrix;
},
},

// TODO I see other refs to NCBI_BioSample in project; good name?
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ivansg44
Copy link
Collaborator Author

I should go through and test everything once more

let atLeastOneWideVal = false;
for (const [i, longHeader] of longHeadersArr.entries()) {
let wideHeader = antibiotic.concat('_', longHeader);
if (longHeader === 'vendor') wideHeader += '_name';
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add comment

outputMatrix.push(longRow);
}
}
// Ensures a row is still added if no antibiotic info is present
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this necessary?

@ddooley ddooley merged commit e86c7be into master Oct 22, 2024
1 check passed
@ddooley ddooley deleted the GRDI-Export-OneHealth-enterics branch October 22, 2024 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wip Work in progress
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants