marianschmidt / msspchelpr Goto Github PK
View Code? Open in Web Editor NEWR helper functions for Second Primary Cancer analyses
Home Page: http://marianschmidt.github.io/msSPChelpR
License: GNU General Public License v3.0
R helper functions for Second Primary Cancer analyses
Home Page: http://marianschmidt.github.io/msSPChelpR
License: GNU General Public License v3.0
check that all changes in calculations for asir_results with futime_src="refpop" are also reflected in "cohort" calculations (first half of function)
Currently, the asir function assumes that for all regions the same period of data registration was applied. However, in case you included regional registries that have collected data for different time periods, this should be defined in the function call and the calculations should take this into account.
NAs should appear in final results table. Expected would be 0.
so far summarize_group = c("region", "year", "sex") have been implemented as they are distinct and we can simply add up observed counts and PYARs.
Does it make sense to summarize asir over multiple icdcat and how could that be implemented into asir function?
make a new function ir_crosstab_futime and include this new function to be optionally called from ir_crosstab
.shallow(x, cols = cols, retain.key = TRUE) :
can't set ALTREP truelength
Check if some unclean version of data is returned by _dt() functions or whether key needs to be reset at beginning.
tidyr release: check all functions whether they use nest() or unnest(); check whether existing functions can profit from new vignette("rectangle")
Check functions *_byfutime for bug where pyar can temporarily be negative and thus sum(i_pyar) is wrongly calculated
--> may apply to crosstab_byfutime
(function sir_byfutime was developed after bug was identified)
group_by --> change add to .add
mutate_at/_if/_all --> use new dplyr::across function
see https://www.tidyverse.org/blog/2020/03/dplyr-1-0-0-is-coming-soon/
Checklist
bind_cols()
should not be expected to convert to tibblen()
and row_number()
need dplyr::
prefixall.equal.tbl_df()
should not be usedfuns()
should be replaced by list()
group_by(add = )
needs to be replaced by .add
sample_n()
and sample_frac()
need to be replaced by slice_sample(n = )
and slice_sample(prop = )
mutate_*
, group_by_*
, select_*
and rename_*
sections need to bee rewritten using across()
add_total_fu
add_total_row
output_information
output = "nested"
finalize checks of options and expected errors in function implementation
Function should be constructed as
filter_long(long_df, keep_cond="", reverse = FALSE){
1 create new dummy variable keep that is 1 if keep_cond == TRUE
2 filter based on keep == 1 or on keep= 0, if reverse ==TRUE
}
keep_condition could be tidyverse filter expression (capture 3 dots?)
Error code
kein nicht-fehlendes Argument f�r min; gebe Inf zur�ckkein nicht-fehlendes Argument f�r max; gebe -Inf zur�ckCan't set value labels for "p_status". Infinite value range.
aim give a new sequence in numbering tumor ids per patient in long dataset version
output = "wide" does not work with add_total_row (fu_time_sort needs to be filled before reshaping)
check that add_total_row works with add_total_futime
check if year futime_breaks are correctly handled in all functions
ztest_dev %>%
summarize_sir_results_dev(.,
summarize_groups = c("age", "region", "sex", "year"),
summarize_site = FALSE,
output = "wide",
output_information = "minimal",
add_total_row = "start",
add_total_fu = "start",
collapse_ci = FALSE,
shorten_total_cols = FALSE,
fubreak_var_name = "fu_time",
ybreak_var_name = "yvar_name",
xbreak_var_name = "none",
alpha = 0.05)
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.