When groupvar is not provided, 1. The function outputs a GeoMx S4 class with length same as length of ROIs, sizefact, in phenoData. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L20 2. The function outputs a GeoMx S4 class with length same as length of negative probes, featfact, in featureData. The value is NA for non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L23 3. If size_scale="first", sizefact[1]=1 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L30 4. If size_scale="sum", sum(sizefact)=1 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L34
When groupvar is provided but not found in the phenodata, 1. The function returns an error saying this groupvar is not found in the S4 object. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L49
When groupvar is provided and found in the phenodata, but the it only has one unique value, 1. The function returns a warning message saying that the groupvar has only one value test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L63
When groupvar is provided and found in the phenodata with more than one unique value, 1. The function outputs a GeoMx S4 class with length same as length of ROIs, sizefact_sp, in phenoData. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L95 2. The function outputs a GeoMx S4 class with length same as length of negative probes, featfact_sp, in featureData for each unique slide value. The value is NA for non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L91 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L99 3. If size_scale="first", sizefact[1]=1 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L115 4. If size_scale="sum", sum(sizefact)=1 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisBG.R#L119
When split is FALSE, 1. The function outputs a GeoMx S4 class with p values in featureData with length same as length of probes. The p value is NA for negative targets. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L41 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L87 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L132 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L177 2. The function outputs a GeoMx S4 class with score values in featureData with length same as length of targets. The score value is NA for negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L52 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L97 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L142 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L187 3. All p values are between 0 and 1 (inclusive) for non-negative features. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L62 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L107 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L152 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L197 4. The length of non-NA p values is equal to the number of non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L67 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L112 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L157 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L202 5. The length of non-NA scores values is equal to the number of non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L70 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L115 6. The order of pvalues is the same as scores. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L73 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L118 7. It returns an error without running fitPoisBG. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L508 8. It returns an error if split is TRUE but no corresponding fitPoisBG is called previously. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L534
When split is TRUE, 1. The function outputs a GeoMx S4 class with p values in featureData with length same as length of targets for each unique slide value. The p value is NA for negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L246 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L309 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L373 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L437 2. The function outputs a GeoMx S4 class with score values in featureData with length same as length of targets for each unique slide value. The score value is NA for negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L260 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L323 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L387 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L450 3. All p values are between 0 and 1 (inclusive) for non-negative features. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L272 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L335 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L399 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L462 4. The length of non-NA p values is equal to the number of non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L278 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L341 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L405 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L468 5. The length of non-NA scores values is equal to the number of non-negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L291 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L354 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L418 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L481 6. The order of pvalues is the same as scores. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L297 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L360 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L424 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-scoretest.R#L487
When split is FALSE, 1. Without providing values for ROIs_high, features_high, features_all, sizefact_start, sizefact_BG, the function returns the same value test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L128 2. User need to set iterations =2 for now test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L77 3. The function outputs a GeoMx S4 class with para0, matrix of estimated parameters, in the featureData. This matrix para0 has the following structure: 3.1) 1 row for each feature (row name). If a feature is not in features_high, all columns will be NA. 3.2) n+1 columns labeled var1, var2, ..., var, var where n is the length of ROIs_high elements. 3.3) the n columns will have log2 expression (if feature is in features_high) or NA (otherwise). 3.4) the n+1th column contains the threshold for each feature in features_high and NA otherwise. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L134 4. The function outputs a GeoMx S4 class with para, matrix of estimated parameters, in the featureData. This matrix para has the following structure: 4.1) 1 row for each feature (row name) which is equal to the length of features_all 4.2) n+1 columns labeled var1, var2, ..., var, var where n is the length of ROIs_high elements. 4.3) the n columns will have log2 expression. 4.4) the n+1th column contains the threshold for each feature in features_all. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L153 5. The function outputs a column called conv0 in featureData, with values in [NA, 0] and length of 0s are the same as the length of features_high. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L169 6. The function outputs a column called conv in featureData, length same as features_all, and has values [NA, 0, 1]. The length of NAs equals the number of negative probes. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L178 7. when confac=0 and prior_type="contrast", preci1_norm value in experimentData will be single value repeated over an n-by-n matrix (where n is the length of ROI_high). This single value is equivalent, within 10 digits, to preci1con/n^2. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L189 8. It returns an error without running fitPoisBG or fitNBth. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L222 9. It returns an error if split is TRUE but no corresponding fitPoisBG is called previously. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L267
When split is TRUE, 1. Without providing values for ROIs_high, features_high, features_all, sizefact_start, sizefact_BG, the function returns the same value test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L385 2. Given a GeoMx S4 object, fitPoisthNorm_sp runs the Poisson model-based normalization and log2 transformation on each element in "groupvar" individually. As such, the results for a given grouping/facet of the data should match the fitPoisthNorm results when an object is subset down to a single slide. Specifically, the following should be true: test: 2.1) For a given element in groupvar, the corresponding column in the "threshold0" matrix, which is within featureData, should be identical to the single-patient case's fetureData's para0[,n+1]th column. 2.2) For a given element in groupvar, the corresponding column in the "threshold" matrix, which is within featureData, should be identical to the single-patient case's fetureData's para[,n+1]th column. 2.3) For a given element in groupvar, the normalized matrix "normmat0_sp", in the assayData slot, should be identical to that element's "normmat0" matrix, also in the assayData slot, for all samples within that element. In other words, the matrix within the "single slide" results (normmat0) should be a subset of the "multiple slide" results (normmat_sp). 2.4) For a given element in groupvar, the normaized matrix "normmat_sp", in the assayData slot, should be identical to that element's "normmat" matrix, also in the assayData slot, for all samples within that element. In other words, the matrix within the "single slide" results (normmat) should be a subset of the "multiple slide" results (normmat_sp). 2.5) For a given element in groupvar, the vector of sizefact, located in phenoData's sizefact_norm column, is identical to that element's sizefact_norm vector from running fitPoisthNorm (i.e., single grouping case). 2.6) For a given element in groupvar, the vector of sizefact0, located in phenoData's sizefact_norm column, is identical to that element's sizefact_norm0 vector from running fitPoisthNorm (i.e., single grouping case). test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitPoisthNorm.R#L413
1.The function outputs para0, a matrix of estimated parameters in iter=1. This matrix has features_high in the columns and parameters(regression coefficients, threshold, r) in the rows. Both threshold and r are positive. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L75 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L238 2.The function outputs para, a matrix of estimated parameters in iter=2. This matrix has features_all in the columns and parameters(regression coefficients, threshold, r) in the rows. Both threshold and r are positive. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L114 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L276 3.The function outputs sizefact, a vector of size factors, when sizefactrec=FALSE, sizefact is the same as sizefact_start. test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L128 test: https://github.com/Nanostring-Biostats/GeoDiff/blob/eef13efc1636fd86e3b833c26967d3fb2c350396/tests/testthat/test-fitNBthDE.R#L290
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.