worldhealthorganization / lab2godata Goto Github PK
View Code? Open in Web Editor NEWShiny app to support with importing lab results into Go.Data
License: Other
Shiny app to support with importing lab results into Go.Data
License: Other
Problem statement:
The match_cases()
function example is not working. It appears that there is a bug in godataR::get_labresults_epiwindow()
. Although this function is able to retrieve the lab data from Go.Data, the case information based on a query with a list of Go.Data case IDs is failing to export (the export log ID returns NULL
).
Here is the json query that is failing:
{
"filter": {
"where": {
"visualId": {
"$in": ["C-2022-0002", "C-2022-0003", "C-2022-0004"]
},
"useDbColumns": "true",
"dontTranslateValues": "true",
"jsonReplaceUndefinedWithNull": "true"
},
"fields": ["id", "visualId", "firstName", "lastName", "dob", "age.years", "documents.number", "dateOfReporting", "dateOfOnset", "type"]
}
}
This query is passed to cases/exports/
as below:
# Send the Go.Data case ID query to Go.Data and fetch the export log ID:
elid = httr::POST(url =
# Construct request API URL:
paste0(url,
"api/outbreaks/",
outbreak_id,
"/cases/export?access_token=",
get_access_token(url = url,
username = username,
password = password)),
# Set the content type:
httr::content_type_json(),
# Add query:
body = query_json_c,
encode = "raw") %>%
# Fetch content:
httr::content() %>%
# Extract export log ID from content:
purrr::pluck("exportLogId")
Problem statement:
The lab2godata
shiny app currently has quite a number of options to fill - this means a lot of selections for the user, which could be tedious if they have to reselect all the parameters each time they use the app.
Proposed solution:
Save user inputs as a .rda
file, which if present on the user's computer, will automatically load the next time the app is launched.
Note the following:
.rda
file, load it if it exists and apply the saved inputs is a more appropriate approach..rda
file is loaded at the top of the script, outside of the UI and server (if it exists).matchcols
input parameter during a session, the variable names to map will automatically change and they will have to select the relevant new variable(s) from the drop-down list.A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.