How to fix Error in `$<-.data.frame`(`*tmp*`, "Kingdom", value = character(0)) : replacement has 0 rows, data has 2407
1
0
Entering edit mode
6.3 years ago
arsilan324 ▴ 90

Hi all, I am stuck with this error.

Error in `$<-.data.frame`(`*tmp*`, "Kingdom", value = character(0)) : 
  replacement has 0 rows, data has 2407

This is what I get after running this command

amp_rabund(data = physeqP,
           tax.aggregate = "Genus",
           tax.add = "Phylum",
           scale.seq = 100)

This is how my phyloseq object (data) looks like

> physeqP
phyloseq-class experiment-level object
otu_table()   OTU Table:         [ 2407 taxa and 73 samples ]
sample_data() Sample Data:       [ 73 samples by 3 sample variables ]
tax_table()   Taxonomy Table:    [ 2407 taxa by 6 taxonomic ranks ]

I have tried to do it on data subset as well but it fails every time. I am not even able to understand what problem it is. The instructions i am following are given in this link

http://madsalbertsen.github.io/ampvis/examples/ampvis_guide.html

I would be very thankful if you please help me fix the issue... Thanks in advance Arslan

Rank abundance Phyloseq • 13k views
ADD COMMENT
0
Entering edit mode

You need to show the actual command producing this error and some context surrounding it.

ADD REPLY
0
Entering edit mode

Apologies. Here is the command.

amp_rabund(data = dsn,
           tax.aggregate = "Genus",
           tax.add = "Phylum",
           scale.seq = 100)
ADD REPLY
0
Entering edit mode
6.3 years ago
arsilan324 ▴ 90

The new version ampvis2 worked perfectly. Thanks!

ADD COMMENT

Login before adding your answer.

Traffic: 2342 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6