NEWS.md
format.sumstats.for.magma
package_version comparisons now only work with strings instead of numbers.get_data / get_ctd
.token arg.tag arg.rworkflows
badger
get_ctd_dendro
plot_celltype_associations
sprintf, for,patchwork
ggplot2::ggsave instead of grDevices
bind_plots
enrichment_results
levels.%>% with |> syntax.celltype_associations_pipeline:
get_ctd
map_snps_to_genes
genesOut path for Windows.check_n, check_genomeLocFile
enrichment_results:
calculate_conditional_celltype_associations
qvalue_thresh
magma_tileplot
grDevices / gridExtra with patchwork
fix_celltype_names2 for situations when you don’t want to make all celltypes in vector unique.check_n funcplot_celltype_associations
ctAssocs and ctdDendro are both run through EWCE::fix_celltype_names() when creating an ordered factor.merge_magma_results
calculate_celltype_associations:
calculate_celltype_associations_linear, calculate_celltype_associations_top10
EnrichmentMode gets added to the saved file names to distinguish results from one another via new internal func: check_analysis_name.load_magma_results_file
res$COVAR column, as this is no longer relevant given the structure of the results table.rownames(res) <- res$VARIABLE as this causes duplicate rownames.keep_types= to subset results types.map_snps_to_genes
import_magma_files:
data.tables.magma_files_metadata
celltype_associations_pipeline:
standardise arg.adjust_zstat_in_genesOut:
ctd and geneset species by default:
infer_ctd_speciesinfer_geneset_speciesmap_snps_to_genes:
N when =NULL or =NA.genes_only arg to make function faster and skip generating “genes.raw” file.check_quantiles:
EWCE::standardise_ctd).decompress
storage_dir instead of tempdir().full_workflow vignette to work.magma_tileplot:
get_example_gwas:
tempdir() to make easier to infer MAGMA output file paths in vignettes.merge_results:
save_dir if not already present.get_driver_genes:
magma_files_metadata:
calculate_conditional_celltype_enrichment_limma example working again.get_ctd:
EWCE::standardise_ctd function.tempdir).get_genome_ref saves to cache dir (not temp dir) during map_snps_to_genes.get_data, specifically get_genomeLocFile.paste instead of file.path to avoid cross-platforms issues (e.g. Windows inserting “" instead of”/“).dir.create to get_data.get_example_gwas_raw: Allow users to specify timeout when downloading raw (pre-munged) files.MAGMA.Celltyping was revamped to meet CRAN standards, automatically install MAGMA, and take any species are input.NEWS.md file to track changes to the package.magma_install function; stores binaries in MAGMA.Celltyping-specific cache dir. Added various support functions to make this possible and ensure correct version is being used.magma_uninstall function to remove one or all MAGMA binaries.MAGMA.Celltyping to install even if MAGMA is not installed. Instead, check at the beginning of functions that require MAGMA using magma_check.
magma_links_stored: Include built-in metadata with links to all MAGMA versions with parsed version numbers, OS, and which is the latest version.magma_run which finds the requested version of MAGMA and uses it.magma_cmd function.get_sub_SNP_LOC_DATA
.Deprecated function and removing all other internal code:
get_genomebuild_for_sumstatsbuild_snp_location_tablesformat.sumstats.for.magmaformat_sumstats_for_magma_macOnlystandardise.sumstats.column.headersstandardise.sumstats.column.headers.crossplatformsumstatsColHeaders from data, as it was only used in now-deprecated functions.calculate.celltype.enrichment.probabilities.wtLimma –> calculate_celltype_enrichment_limma
calculate.conditional.celltype.enrichment.probabilities.wtLimma –> calculate_conditional_celltype_enrichment_limma
piggyback-based functions:
get_ctd: CellTypeDatasetsget_example_gwas: GWAS summary statsget_genomeLocFile: NCBI gene coordinate references.MungeSumstats). Accessed by get_example_gwas.
get_genome_refprepare_quantile_groupsreshapecowplotSNPlocs.Hsapiens.dbSNP144.GRCh37SNPlocs.Hsapiens.dbSNP144.GRCh38hgnc2entrez with improved hgnc2entrez_ortohgene from orthogene::all_genes. Benchmarked to confirm that the latter increases the number of genes that can be converted.output_species (default: “human”) using orthogene.MungeSumstats: MAGMA_Files_Public
magma_files_metadata: Built-in table of all pre-processed MAGMA files currently in the database.import_magma_files.calculate_celltype_associations(magma_dir="<folder_containing_magma_files>") This function is also used for downloading MAGMA files in examples/unit tests.@title,@description,@param, @return for all exported (and many internal) functions.@examples for all exported (and many internal) functions.@importFrom or requireNamespace for all imports functions.1:10 syntax.upstream_kb = 35downstream_kb = 10get_genome_ref(population = "<population_name>")
EWCE features in bschilder_dev branch:
EWCE::standardise_ctd
celltype_associations_pipeline, which lets users specify which test they want to run with arguments, including:
calculate_celltype_associations (Linear mode)calculate_celltype_associations (Top10% mode)calculate_conditional_celltype_associationscelltype_associations_pipeline across multiple cores.normalise_mean_expbin_specificityDistance_into_quantilesbin_expression_into_quantilesget_driver_genescalculate_celltype_enrichment_limmaadjust_zstat_in_genesOutusethis call from code.library calls from code.data.frame
suppressWarnings calls and resolve the underlying issues instead.utils as Suggest.plot_celltype_associations, first reported here.prepare_quantile_groups so that it’s consistent with how EWCE compute specificity quantiles. Ensures that all celltypes (columns) have exactly the same number of quantiles, which was not the case before.