Return the TwasWeightsRow for one (study,
context, trait, method) row of a TwasWeights collection.
Usage
getTwasWeights(x, study = NULL, context = NULL, trait = NULL, method = NULL)
# S4 method for class 'TwasWeights'
getTwasWeights(x, study = NULL, context = NULL, trait = NULL, method = NULL)Examples
twe <- twasWeightsRow(
variantIds = sprintf("chr1:%d:A:G", 100L * (1:4)), weights = rep(0.1, 4),
cvResult = list(rsq = 0.5), standardized = FALSE)
tw <- TwasWeights(study = "s1", context = "brain", trait = "g1",
method = "susie", entry = list(twe))
getTwasWeights(tw, study = "s1", context = "brain", trait = "g1",
method = "susie")
#> TwasWeights: 1 entries
#> 1 studies, 1 contexts, 1 traits, 1 methods
#> LD sketch: NULL (individual-level fit)