Phylogenetic tree with 3 tips and 2 internal nodes.
Tip labels:
HFC, HMC, LFC
Rooted; includes branch lengths.
> ac1 <- anc.clim(target = tr, pno = clim, n = 100)
Error in data.frame(x) : row names contain missing values
此外: Warning messages:
1: In FUN(newX[, i], ...) :
the names of 'x' and the tip labels of the tree do not match: the former were ignored in the analysis.
2: In Initialize.corPhyl(corStruct, data.frame(x)) :
No covariate specified, species will be taken as ordered in the data frame. To avoid this message, specify a covariate containing the species names with the 'form' argument.
####软件包的test数据
> tree
Phylogenetic tree with 5 tips and 4 internal nodes.
Tip labels:
adenophylla, arenaria, laciniata, enneaphylla, loricata
Rooted; includes branch lengths.
> clim1 <- PNO$PrecipitationWarmestQuarter
> head(clim1)
variable adenophylla arenaria enneaphylla laciniata loricata
1 0.00000 0.02225193 0.39616046 0.0004981347 0.005570378 0.002770169
2 38.44898 0.56936564 0.28548473 0.0483867934 0.090354572 0.327931308
3 76.89796 0.20232050 0.19529811 0.0630264096 0.363138573 0.142187408
4 115.34694 0.10365486 0.08120637 0.0266872031 0.167960728 0.088057939
5 153.79592 0.06196568 0.02861484 0.0256178105 0.148677108 0.075511689
6 192.24490 0.02866730 0.01053544 0.0328056103 0.057139103 0.063873678
> ac <- anc.clim(target = tree, pno = clim1, n = 100)
There were 50 or more warnings (use warnings() to see the first 50)
赖老师,您好:
我在对植物的性状值做PCA分析的时候,因为有缺失值,看了您的博文然后用了那个missMDA包里的imputPCA函数,结果出现错误信息:Error: Must use a vector in `[`, not an object of class matrix. 想请问一下老师这个是什么原因导致的呢?盖怎么解决呢?谢谢老师!