the training and prediction results from bootstrap were written to the object LSOLDA_dat, the reformat_LASSO summarises prediction for n bootstrap runs

reformat_LASSO(
  c_selectID = NULL,
  mp_selectID = NULL,
  LSOLDA_dat = NULL,
  nPredSubpop = NULL,
  Nodes_group = "#7570b3",
  nboots = 2
)

Arguments

c_selectID

is the original cluster to be projected

mp_selectID

is the target mixedpop to project to

LSOLDA_dat

is the results from the bootstrap

nPredSubpop

is the number of clusters in the target mixedpop row_cluster <-length(unique(target_cluster))

Nodes_group

string representation of hexidecimal color code for node

nboots

is an integer for how many bootstraps are run

Value

a dataframe containg information for the Lasso prediction results, each column contains prediction results for all subpopulations from each bootstrap run

Examples

c_selectID<-1 day2 <- day_2_cardio_cell_sample mixedpop1 <-new_scGPS_object(ExpressionMatrix = day2$dat2_counts, GeneMetadata = day2$dat2geneInfo, CellMetadata = day2$dat2_clusters) day5 <- day_5_cardio_cell_sample mixedpop2 <-new_scGPS_object(ExpressionMatrix = day5$dat5_counts, GeneMetadata = day5$dat5geneInfo, CellMetadata = day5$dat5_clusters) genes <-training_gene_sample genes <-genes$Merged_unique LSOLDA_dat <- bootstrap_prediction(nboots = 2, mixedpop1 = mixedpop1, mixedpop2 = mixedpop2, genes=genes, c_selectID, listData =list(), cluster_mixedpop1 = colData(mixedpop1)[,1], cluster_mixedpop2=colData(mixedpop2)[,1])
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> done training for bootstrap 1, moving to prediction...
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> Warning: variables are collinear
#> done training for bootstrap 2, moving to prediction...
reformat_LASSO(LSOLDA_dat=LSOLDA_dat, nPredSubpop=length(unique(colData(mixedpop2)[,1])), c_selectID = 1, mp_selectID =2, nboots = 2)
#> Boostrap1 Boostrap2 Target Source Node NodeGroup Value #> 1 35.2941176470588 29.4117647058824 C1_MP2 C1_MP2 C1_MP2 #7570b3 32.35294 #> 2 1.42857142857143 22.8571428571429 C2_MP2 C1_MP2 C1_MP2 #7570b3 12.14286 #> 3 0 90.2255639097744 C3_MP2 C1_MP2 C1_MP2 #7570b3 45.11278 #> 4 2.5 67.5 C4_MP2 C1_MP2 C1_MP2 #7570b3 35.00000