Dear Dean,
Kindly appreciate your message, I follow your suggestion, uninstall both libraries, geomorph and RRPP, and then install directly from github using devtools and the problem persists. I spent several hours trying to solve the problem without success :(
This is what I am doing:
landmarks=readland.tps("test.tps",specID="None")
Procrustes=gpagen(landmarks)
phy=read.tree("Oscar.tre")
gdf2 <- geomorph.data.frame(Procrustes,phy=phy)
attributes(gdf2)
Preliminary Model Fit...
Error: Data names and covariance matrix names do not match.
#### I check the names in both, my tps and phylogeny and apparently match###
name.check(Procrustes,phy)
[1] "OK"
##but i found errors with this function###
match(rownames(Procrustes),phy$tip.labels)
integer(0)
obj<-name.check(phy,landmarks)
obj
$tree_not_data
[1] "Chuco_intermedium" "Chuco_microphthalmus"
[3] "Cincelichthys_pearsei" "Kihnichthys_ufermanni"
[5] "Maskaheros_argenteus" "Maskaheros_regani"
[7] "Oscura_heterospila" "Paraneetroplus_bulleri"
[9] "Paraneetroplus_nebuliferus" "Rheoheros_lentiginosus"
[11] "Theraps_irregularis" "Trichromis_salvini"
[13] "Vieja_bifasciata" "Vieja_breidohri"
[15] "Vieja_fenestrata" "Vieja_guttulata"
[17] "Vieja_hartwegi" "Vieja_maculicauda"
[19] "Vieja_melanurus" "Vieja_zonata"
[21] "Wajpamheros_nourissati"
$data_not_tree
NULL
###### I see that my coords have not name###
dim(Procrustes$coords)
[1] 44 2 21
dimnames(Procrustes$coords)
[[3]]
[1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15"
[16] "16" "17" "18" "19" "20" "21"
### I follow suggestions and assign names ####
newnames=c("Paraneetroplus_nebuliferus","Chuco_intermedium","Chuco_microphtalmus","Cincelichthys_pearsei","Kihnichthys_uefermanni","Maskaheros_argenteus","Maskaheros_regani","Oscura_heterospila","Paraneetroplus_bulleri","Rheoheros_lentiginosus","Theraps_irregularis","Thrichromis_salvini","Vieja_bifasciata","Vieja_breidhori","Vieja_fenestrata","Vieja_gutttulata","Vieja_hartwegii","Vieja_maculicauda","Vieja_melanurus","Vieja_zonata","Wajpamheros_nourisatti")
dimnames(Procrustes$coords)[[3]]=newnames
dimnames(Procrustes$coords)
### Now my coords have a name ###
[[3]]
[1] "Paraneetroplus_nebuliferus" "Chuco_intermedium"
[3] "Chuco_microphtalmus" "Cincelichthys_pearsei"
[5] "Kihnichthys_uefermanni" "Maskaheros_argenteus"
[7] "Maskaheros_regani" "Oscura_heterospila"
[9] "Paraneetroplus_bulleri" "Rheoheros_lentiginosus"
[11] "Theraps_irregularis" "Thrichromis_salvini"
[13] "Vieja_bifasciata" "Vieja_breidhori"
[15] "Vieja_fenestrata" "Vieja_gutttulata"
[17] "Vieja_hartwegii" "Vieja_maculicauda"
[19] "Vieja_melanurus" "Vieja_zonata"
[21] "Wajpamheros_nourisatti"
## names apparently are ok ###
name.check(Procrustes,phy)
[1] "OK"
### but not ###
match(rownames(Procrustes),phy$tip.labels)
integer(0)
obj<-name.check(phy,landmarks)
obj
$tree_not_data
[1] "Chuco_intermedium" "Chuco_microphthalmus"
[3] "Cincelichthys_pearsei" "Kihnichthys_ufermanni"
[5] "Maskaheros_argenteus" "Maskaheros_regani"
[7] "Oscura_heterospila" "Paraneetroplus_bulleri"
[9] "Paraneetroplus_nebuliferus" "Rheoheros_lentiginosus"
[11] "Theraps_irregularis" "Trichromis_salvini"
[13] "Vieja_bifasciata" "Vieja_breidohri"
[15] "Vieja_fenestrata" "Vieja_guttulata"
[17] "Vieja_hartwegi" "Vieja_maculicauda"
[19] "Vieja_melanurus" "Vieja_zonata"
[21] "Wajpamheros_nourissati"
$data_not_tree
NULL
#### I compare the order of the names in both, Procrustes$coords and tiplabels,
I assume that R needs that the names must be in the same position to match###
dimnames(Procrustes$coords)
[[3]]
[1] "Paraneetroplus_nebuliferus" "Chuco_intermedium"
[3] "Chuco_microphtalmus" "Cincelichthys_pearsei"
[5] "Kihnichthys_uefermanni" "Maskaheros_argenteus"
[7] "Maskaheros_regani" "Oscura_heterospila"
[9] "Paraneetroplus_bulleri" "Rheoheros_lentiginosus"
[11] "Theraps_irregularis" "Thrichromis_salvini"
[13] "Vieja_bifasciata" "Vieja_breidhori"
[15] "Vieja_fenestrata" "Vieja_gutttulata"
[17] "Vieja_hartwegii" "Vieja_maculicauda"
[19] "Vieja_melanurus" "Vieja_zonata"
[21] "Wajpamheros_nourisatti"
phy$tip.label
[1] "Chuco_microphthalmus" "Chuco_intermedium"
[3] "Cincelichthys_pearsei" "Kihnichthys_ufermanni"
[5] "Theraps_irregularis" "Wajpamheros_nourissati"
[7] "Rheoheros_lentiginosus" "Oscura_heterospila"
[9] "Maskaheros_argenteus" "Maskaheros_regani"
[11] "Paraneetroplus_bulleri" "Paraneetroplus_nebuliferus"
[13] "Vieja_bifasciata" "Vieja_breidohri"
[15] "Vieja_hartwegi" "Vieja_fenestrata"
[17] "Vieja_guttulata" "Vieja_zonata"
[19] "Vieja_maculicauda" "Vieja_melanurus"
[21] "Trichromis_salvini"
### I cannot change my phylogeny topology, so, I change the order of
the species in my tps file and set names according to phy tip labels ##
newnames2=c("Chuco_microphtalmus","Chuco_intermedium","Cincelichthys_pearsei","Kihnichthys_uefermanni","Theraps_irregularis", "Wajpamheros_nourisatti", "Rheoheros_lentiginosus", "Oscura_heterospila","Maskaheros_argenteus","Maskaheros_regani","Paraneetroplus_bulleri","Paraneetroplus_nebuliferus","Vieja_bifasciata","Vieja_breidhori","Vieja_hartwegii","Vieja_fenestrata","Vieja_gutttulata","Vieja_zonata","Vieja_maculicauda","Vieja_melanurus","Thrichromis_salvini")
dimnames(Procrustes$coords)[[3]]=newnames2
dimnames(Procrustes$coords)
[[3]]
[1] "Chuco_microphtalmus" "Chuco_intermedium"
[3] "Cincelichthys_pearsei" "Kihnichthys_uefermanni"
[5] "Theraps_irregularis" "Wajpamheros_nourisatti"
[7] "Rheoheros_lentiginosus" "Oscura_heterospila"
[9] "Maskaheros_argenteus" "Maskaheros_regani"
[11] "Paraneetroplus_bulleri" "Paraneetroplus_nebuliferus"
[13] "Vieja_bifasciata" "Vieja_breidhori"
[15] "Vieja_hartwegii" "Vieja_fenestrata"
[17] "Vieja_gutttulata" "Vieja_zonata"
[19] "Vieja_maculicauda" "Vieja_melanurus"
[21] "Thrichromis_salvini"
phy$tip.label
[1] "Chuco_microphthalmus" "Chuco_intermedium"
[3] "Cincelichthys_pearsei" "Kihnichthys_ufermanni"
[5] "Theraps_irregularis" "Wajpamheros_nourissati"
[7] "Rheoheros_lentiginosus" "Oscura_heterospila"
[9] "Maskaheros_argenteus" "Maskaheros_regani"
[11] "Paraneetroplus_bulleri" "Paraneetroplus_nebuliferus"
[13] "Vieja_bifasciata" "Vieja_breidohri"
[15] "Vieja_hartwegi" "Vieja_fenestrata"
[17] "Vieja_guttulata" "Vieja_zonata"
[19] "Vieja_maculicauda" "Vieja_melanurus"
[21] "Trichromis_salvini"
##Now the names are identical and in the same position, but the trouble persists##
name.check(Procrustes,phy)
[1] "OK
match(rownames(Procrustes),phy$tip.labels)
integer(0)
obj<-name.check(phy,landmarks)
obj
$tree_not_data
[1] "Chuco_intermedium" "Chuco_microphthalmus"
[3] "Cincelichthys_pearsei" "Kihnichthys_ufermanni"
[5] "Maskaheros_argenteus" "Maskaheros_regani"
[7] "Oscura_heterospila" "Paraneetroplus_bulleri"
[9] "Paraneetroplus_nebuliferus" "Rheoheros_lentiginosus"
[11] "Theraps_irregularis" "Trichromis_salvini"
[13] "Vieja_bifasciata" "Vieja_breidohri"
[15] "Vieja_fenestrata" "Vieja_guttulata"
[17] "Vieja_hartwegi" "Vieja_maculicauda"
[19] "Vieja_melanurus" "Vieja_zonata"
[21] "Wajpamheros_nourissati"
$data_not_tree
NULL
##### I update geomorph and RRPP directly from Github and also update Matrix library##
I am using R 4.5.1, geomorph 4.0.10, RRPP 2.1.2 and Matrix 1.7-3
Kindly appreciate any help
Best regards