Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Maintenance - Mise à jour mensuelle Lundi 6 Février entre 7h00 et 9h00
Open sidebar
migale
affiliationExplorer
Commits
93850786
Commit
93850786
authored
Jan 21, 2020
by
Sandra Derozier
Browse files
Fix bug with filter when dplyr is not loaded
parent
024667b2
Changes
1
Hide whitespace changes
Inline
Side-by-side
R/utils.R
View file @
93850786
...
...
@@ -43,14 +43,14 @@ sanitize_physeq_and_affi <- function(physeq, affi) {
old_to_new
<-
otu_dictionary
%>%
dplyr
::
select
(
-
abundance
)
%>%
tibble
::
deframe
()
## Add abundance information to affiliation table
affi
<-
inner_join
(
otu_dictionary
,
affi
,
by
=
c
(
"sequence"
=
"#observation_name"
))
%>%
affi
<-
dplyr
::
inner_join
(
otu_dictionary
,
affi
,
by
=
c
(
"sequence"
=
"#observation_name"
))
%>%
tidyr
::
separate
(
blast_taxonomy
,
into
=
phyloseq
::
rank_names
(
physeq
),
sep
=
";"
)
## Rename taxa in physeq object
phyloseq
::
taxa_names
(
physeq
)
<-
old_to_new
[
phyloseq
::
taxa_names
(
physeq
)]
%>%
unname
()
## Remove previously curated taxa from affi
affi
<-
affi
%>%
filter
(
OTU
%in%
ambiguous_taxa
(
physeq
))
affi
<-
affi
%>%
dplyr
::
filter
(
OTU
%in%
ambiguous_taxa
(
physeq
))
list
(
physeq
=
physeq
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment