microbiome / mia

Microbiome analysis
https://microbiome.github.io/mia/
Artistic License 2.0
46 stars 25 forks source link

New arguments for perSampleDominantFeatures #479

Closed himmil closed 4 months ago

himmil commented 7 months ago

420

TuomasBorman commented 6 months ago

Otherwise works. Ready to go after changes mentioned above

TuomasBorman commented 6 months ago

You can run this for tests, if you haven't already

devtools::load_all()
data("GlobalPatterns")
tse <- GlobalPatterns
assay(tse)[20, ] <- assay(tse)["550960", ]

# Finds the dominant taxa.
sim.dom <- perSampleDominantTaxa(tse)
sim.dom <- perSampleDominantFeatures(tse, complete = FALSE)
tse <- addPerSampleDominantFeatures(tse)
colData(tse)$dominant_taxa
tse <- addPerSampleDominantFeatures(tse, complete = TRUE, n = 5)
colData(tse)$dominant_taxa
himmil commented 5 months ago

Now there is an error in package dependencies (not related to the changes). How should I fix it?

TuomasBorman commented 5 months ago

See the log:

2024-01-19T15:00:11.0664027Z make: ** [/usr/local/lib/R/etc/Makeconf:198: readBfaToc.o] Error 1 2024-01-19T15:00:11.0669619Z ERROR: compilation failed for package ‘ShortRead’ 2024-01-19T15:00:11.0671074Z removing ‘/__w/_temp/Library/ShortRead’ 2024-01-19T15:00:11.4060117Z ERROR: dependency ‘ShortRead’ is not available for package ‘dada2’

The dependency packages need to be installed --> When dada2 package is installed, its dependencies are installed --> this ShortRead package gives an error when installed.

Why? I don't know to be honest. This might occur when the system is lacking certain system dependencies. However, I had this similar problem just couple days ago in another package. The problem was solved by itself.

How to fix? --> Run the GHA again.

This problem is little bit related to rworkflows issue --> we should standardize GHA by utilizing rworkflows package.

antagomir commented 4 months ago

@himmil could you check if it is possible to finalize this..?

himmil commented 4 months ago

This is ready now @TuomasBorman

TuomasBorman commented 4 months ago

Seems good!! Bump the version and add info about changes to NEWS file

himmil commented 4 months ago

@TuomasBorman this is ready