morinlab / GAMBLR

Set of standardized functions to operate with genomic data
https://morinlab.github.io/GAMBLR/
MIT License
3 stars 2 forks source link

ashm_rainbow_plot example in vignette is broken #75

Closed rdmorin closed 2 years ago

rdmorin commented 2 years ago

Running the example throws an error complaining about chromosome. This may be related to the new retrieval method for variants in a region or it may be unrelated

ashm_rainbow_plot(mutations_maf = my_mutations, metadata = all_metadata,
                  bed = mybed, region = region, classification_column = "lymphgen", 
                  custom_colours = get_gambl_colours("lymphgen"))

Error: Problem with `filter()` input `..1`. ℹ Input `..1` is `&...`. x object 'Chromosome' not found Run `rlang::last_error()` to see where the error occurred.
mattssca commented 2 years ago

The culprit in this error was that streamlined was forced to TRUE (only keeping two columns of the input maf) in get_ssm_by_region. Fixed by removing streamlined = TRUE (line 1516 in database.R). The plotting function now works the desired way, as does get_ssm_by_region. Changes will be pushed in my next PR.

mattssca commented 2 years ago

Also, streamlined and basic_columns are set to FALSE per default, to avoid any future errors involving functions that call get_ssm_by_region, expecting all columns.

mattssca commented 2 years ago

This was fixed in this PR