Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/remnrem/luna-base
Browse files Browse the repository at this point in the history
  • Loading branch information
remnrem committed Dec 10, 2024
2 parents 660f6e2 + a62a455 commit ea20091
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
name: win-luna.zip
path: ./win-luna.zip
macos-build:
runs-on: macos-12
runs-on: macos-13
steps:
- uses: actions/checkout@v2
- name: Install LightGBM
Expand Down
17 changes: 13 additions & 4 deletions cmddefs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1903,17 +1903,26 @@ void cmddefs_t::init()
add_param( "GPA" , "X" , "TST" , "Predictor variable(s)" );
add_param( "GPA" , "Z" , "AGE,SEX" , "Covariates (nuissance variables)" );
add_param( "GPA" , "nreps" , "1000" , "Number of permutations" );
add_param( "GPA" , "nreps" , "1000" , "Number of permutations" );
add_param( "GPA" , "adj" , "" , "Run all adjusted p-value corrections" );
add_param( "GPA" , "bonf" , "" , "Add Bonferroni-adjusted p-values" );
add_param( "GPA" , "holm" , "" , "Add Holm-adjusted p-values" );
add_param( "GPA" , "fdr-by" , "" , "Add FDR(B&Y)-adjusted p-values" );
add_param( "GPA" , "fdr" , "F" , "Turn off default FDR(B&H) adjusted p-values" );

add_param( "GPA" , "dump" , "" , "Dump data matrix to stdout" );
add_param( "GPA" , "manifest" , "" , "Dump variable maifest to stdout" );

add_table( "GPA" , "X,Y" , "GPA results per pair of predictor (X) and outcome (Y)" );
add_var( "GPA" , "X,Y" , "B" , "Regression coefficient" );
add_var( "GPA" , "X,Y" , "B" , "Regression coefficient" );
add_var( "GPA" , "X,Y" , "T" , "t-statistic" );
add_var( "GPA" , "X,Y" , "P" , "Empirical p-value" );
add_var( "GPA" , "X,Y" , "PADJ" , "Adjusted empirical p-value" );
add_var( "GPA" , "X,Y" , "N" , "Number of observations" );
add_var( "GPA" , "X,Y" , "P" , "Asymptotic p-value" );
add_var( "GPA" , "X,Y" , "P_FDR" , "FDR-adjusted p-value" );
add_var( "GPA" , "X,Y" , "P_FDR_BY" , "FDR(B&Y)-adjusted p-value" );
add_var( "GPA" , "X,Y" , "P_HOLM" , "Holm-adjusted p-value" );
add_var( "GPA" , "X,Y" , "P_BONF" , "Bonferroni-adjusted p-value" );
add_var( "GPA" , "X,Y" , "EMP" , "Empircal p-value" );
add_var( "GPA" , "X,Y" , "EMPADJ" , "Adjusted empirical p-value" );
add_var( "GPA" , "X,Y" , "STRAT" , "DV stratum" );
add_var( "GPA" , "X,Y" , "XSTRAT" , "IV stratum (if X-factors)" );

Expand Down
2 changes: 1 addition & 1 deletion defs/defs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ void globals::init_defs()

version = "v1.1.0 ";

date = "05-Dec-2024";
date = "09-Dec-2024";

//
// Return code
Expand Down
6 changes: 3 additions & 3 deletions stats/gpa.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1345,10 +1345,10 @@ void gpa_t::run()

writer.value( "B" , results.beta[ xvar ][ var ] );
writer.value( "T" , results.t[xvar][ var ] );

writer.value( "N" , (int)X.rows() );
writer.value( "P" , results.p[xvar][ var ] );
writer.value( "P_FDR" , results.fdr_bh( xvar , var ) );

if ( nreps != 0 )
{
writer.value( "EMP" , results.emp[xvar][ var ] );
Expand Down Expand Up @@ -1503,7 +1503,7 @@ void gpa_t::run1X() // correction within X
{
writer.value( "B" , results.beta[ xvar ][ var ] );
writer.value( "T" , results.t[ xvar ][ var ] );

writer.value( "N" , (int)X.rows() );
writer.value( "P" , results.p[xvar][ var ] );
writer.value( "P_FDR" , results.fdr_bh( xvar , var ) );

Expand Down

0 comments on commit ea20091

Please sign in to comment.