setwd("~/Data/TemperatureInAnimals/MammalianMitochondria/")
d<-read.table("compositions.csv", h=T, sep="\t")
d$tot <- rowSums(d[,3:22])
d$ivy <- (d$I + d$V + d$Y + d$W + d$R + d$E + d$L) / d$tot
summary(d)
sp
Bradypus variegatus: 2
Mammut americanum : 2
Rattus norvegicus : 2
Acinonyx jubatus : 1
Acomys cahirinus : 1
Addax nasomaculatus: 1
(Other) :1007
tax
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Laurasiatheria, Chiroptera, Microchiroptera, Vespertilionidae, Myotis : 28
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Primates, Strepsirrhini, Lemuriformes, Lepilemuridae, Lepilemur : 25
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Primates, Strepsirrhini, Lemuriformes, Cheirogaleidae, Microcebus : 18
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Glires, Rodentia, Myomorpha, Muroidea, Muridae, Murinae, Rattus : 16
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Primates, Haplorrhini, Catarrhini, Cercopithecidae, Cercopithecinae, Macaca: 13
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Glires, Rodentia, Myomorpha, Muroidea, Muridae, Murinae, Mus, Mus : 12
(Other) :904
A C D E
Min. :215.0 Min. :19.00 Min. :57.00 Min. : 79.00
1st Qu.:239.0 1st Qu.:23.00 1st Qu.:65.00 1st Qu.: 92.00
Median :245.0 Median :24.00 Median :67.00 Median : 95.00
Mean :245.3 Mean :24.92 Mean :67.33 Mean : 94.34
3rd Qu.:252.0 3rd Qu.:26.00 3rd Qu.:69.00 3rd Qu.: 97.00
Max. :282.0 Max. :38.00 Max. :81.00 Max. :103.00
F G H I
Min. :201.0 Min. :200.0 Min. : 85.00 Min. :256.0
1st Qu.:229.0 1st Qu.:211.0 1st Qu.: 94.00 1st Qu.:325.0
Median :235.0 Median :215.0 Median : 97.00 Median :334.0
Mean :234.7 Mean :214.2 Mean : 97.36 Mean :336.6
3rd Qu.:241.0 3rd Qu.:217.0 3rd Qu.:100.00 3rd Qu.:345.0
Max. :279.0 Max. :229.0 Max. :115.00 Max. :405.0
K L M N
Min. : 83.00 Min. :566.0 Min. :188.0 Min. :133
1st Qu.: 94.00 1st Qu.:593.0 1st Qu.:233.0 1st Qu.:154
Median : 97.00 Median :602.0 Median :246.0 Median :160
Mean : 96.79 Mean :605.3 Mean :244.6 Mean :160
3rd Qu.: 99.00 3rd Qu.:616.0 3rd Qu.:257.0 3rd Qu.:166
Max. :109.00 Max. :660.0 Max. :295.0 Max. :185
P Q R S
Min. :173.0 Min. : 72.0 Min. :57.00 Min. :249.0
1st Qu.:193.0 1st Qu.: 86.0 1st Qu.:63.00 1st Qu.:275.0
Median :196.0 Median : 89.0 Median :64.00 Median :281.0
Mean :197.7 Mean : 88.8 Mean :64.49 Mean :282.9
3rd Qu.:201.0 3rd Qu.: 92.0 3rd Qu.:65.00 3rd Qu.:291.0
Max. :229.0 Max. :104.0 Max. :72.00 Max. :328.0
T V W Y
Min. :261.0 Min. :135.0 Min. : 99 Min. :111
1st Qu.:308.0 1st Qu.:167.0 1st Qu.:103 1st Qu.:128
Median :316.0 Median :179.0 Median :104 Median :132
Mean :321.2 Mean :177.4 Mean :104 Mean :132
3rd Qu.:330.0 3rd Qu.:188.0 3rd Qu.:105 3rd Qu.:137
Max. :412.0 Max. :215.0 Max. :109 Max. :155
X tot ivy
Mode:logical Min. :3713 Min. :0.3827
NA's:1016 1st Qu.:3788 1st Qu.:0.3969
Median :3791 Median :0.3996
Mean :3790 Mean :0.3995
3rd Qu.:3792 3rd Qu.:0.4024
Max. :3801 Max. :0.4164
library(ade4)
coa <- dudi.coa(d[,3:22], scan = F, nf =3)
plot(coa$li)
# Percent explained by the axes:
coa$eig/sum(coa$eig)
[1] 0.339443623 0.226783207 0.137438762 0.055235039 0.050409382
[6] 0.033985699 0.032189083 0.021510590 0.019550620 0.017129379
[11] 0.013902975 0.012789214 0.010788567 0.009048981 0.007677469
[16] 0.004560190 0.003569719 0.002773527 0.001213974
temp <- read.table("Mammals-TemperatureRENAMED.csv", h=T, sep="\t")
summary(temp)
Species Higher.Group Order
: 1 Min. :1.000 Min. : 1.00
Abrothrix longipilis: 1 1st Qu.:3.000 1st Qu.:14.00
Acinonyx jubatus : 1 Median :3.000 Median :14.00
Acomys cahirinus : 1 Mean :3.675 Mean :14.83
Acomys russatus : 1 3rd Qu.:5.000 3rd Qu.:19.00
Aconaemys fuscus : 1 Max. :7.000 Max. :27.00
(Other) :592 NA's :1 NA's :1
Family Genus Species.1
Min. : 1.00 Min. : 1.0 Min. : 1
1st Qu.: 27.00 1st Qu.: 79.0 1st Qu.:150
Median : 31.00 Median :156.0 Median :299
Mean : 44.78 Mean :162.8 Mean :299
3rd Qu.: 66.00 3rd Qu.:248.0 3rd Qu.:448
Max. :127.00 Max. :352.0 Max. :596
NA's :1 NA's :1 NA's :1
Mass.g. Temp.C.
Min. : 2 Min. :30.00
1st Qu.: 31 1st Qu.:35.50
Median : 121 Median :36.70
Mean : 162948 Mean :36.44
3rd Qu.: 1430 3rd Qu.:37.70
Max. :62500000 Max. :40.70
NA's :1 NA's :1
dtemp <- merge(d, temp, by.x="sp", by.y="Species")
summary(dtemp)
sp
Bradypus variegatus: 2
Rattus norvegicus : 2
Acinonyx jubatus : 1
Acomys cahirinus : 1
Ailurus fulgens : 1
Alces alces : 1
(Other) :145
tax
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Laurasiatheria, Pholidota, Manidae, Manis : 5
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Glires, Rodentia, Myomorpha, Muroidea, Muridae, Murinae, Rattus: 4
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Glires, Lagomorpha, Leporidae, Lepus : 3
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Laurasiatheria, Carnivora, Caniformia, Mustelidae, Mustelinae, Mustela : 3
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Laurasiatheria, Carnivora, Caniformia, Ursidae, Ursus : 3
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Mammalia, Eutheria, Euarchontoglires, Glires, Lagomorpha, Ochotonidae, Ochotona : 2
(Other) :133
A C D E
Min. :220.0 Min. :21.00 Min. :60.00 Min. : 82.00
1st Qu.:237.0 1st Qu.:24.00 1st Qu.:66.00 1st Qu.: 92.00
Median :246.0 Median :26.00 Median :67.00 Median : 94.00
Mean :246.1 Mean :26.36 Mean :67.63 Mean : 93.72
3rd Qu.:254.0 3rd Qu.:28.00 3rd Qu.:69.00 3rd Qu.: 96.00
Max. :280.0 Max. :38.00 Max. :81.00 Max. :101.00
F G H I
Min. :205.0 Min. :201.0 Min. : 87.00 Min. :256.0
1st Qu.:227.0 1st Qu.:213.0 1st Qu.: 96.00 1st Qu.:323.0
Median :234.0 Median :216.0 Median : 98.00 Median :335.0
Mean :232.7 Mean :215.4 Mean : 98.99 Mean :338.3
3rd Qu.:238.0 3rd Qu.:217.0 3rd Qu.:102.00 3rd Qu.:354.0
Max. :279.0 Max. :229.0 Max. :113.00 Max. :390.0
K L M N
Min. : 85.00 Min. :571.0 Min. :192.0 Min. :138.0
1st Qu.: 93.00 1st Qu.:594.0 1st Qu.:230.0 1st Qu.:152.0
Median : 96.00 Median :602.0 Median :245.0 Median :157.0
Mean : 96.37 Mean :604.2 Mean :243.2 Mean :157.7
3rd Qu.:100.00 3rd Qu.:615.0 3rd Qu.:256.0 3rd Qu.:164.0
Max. :108.00 Max. :660.0 Max. :295.0 Max. :180.0
P Q R S
Min. :173 Min. :74.00 Min. :61.00 Min. :249.0
1st Qu.:194 1st Qu.:85.00 1st Qu.:64.00 1st Qu.:275.0
Median :197 Median :88.00 Median :65.00 Median :282.0
Mean :198 Mean :88.03 Mean :65.07 Mean :284.4
3rd Qu.:201 3rd Qu.:91.00 3rd Qu.:66.00 3rd Qu.:292.0
Max. :220 Max. :99.00 Max. :70.00 Max. :328.0
T V W Y
Min. :261.0 Min. :145.0 Min. : 99.0 Min. :111
1st Qu.:304.0 1st Qu.:167.0 1st Qu.:103.0 1st Qu.:128
Median :315.0 Median :179.0 Median :104.0 Median :132
Mean :318.7 Mean :178.9 Mean :104.2 Mean :132
3rd Qu.:327.0 3rd Qu.:190.0 3rd Qu.:105.0 3rd Qu.:137
Max. :403.0 Max. :215.0 Max. :108.0 Max. :154
X tot ivy Higher.Group
Mode:logical Min. :3774 Min. :0.3847 Min. :1.000
NA's:153 1st Qu.:3787 1st Qu.:0.3970 1st Qu.:3.000
Median :3790 Median :0.4003 Median :5.000
Mean :3790 Mean :0.4001 Mean :4.176
3rd Qu.:3792 3rd Qu.:0.4039 3rd Qu.:5.000
Max. :3798 Max. :0.4164 Max. :7.000
Order Family Genus Species.1
Min. : 1.00 Min. : 1.00 Min. : 1.0 Min. : 1.0
1st Qu.:13.00 1st Qu.: 25.00 1st Qu.: 67.0 1st Qu.:112.0
Median :16.00 Median : 53.00 Median :205.0 Median :389.0
Mean :15.77 Mean : 54.58 Mean :186.2 Mean :335.8
3rd Qu.:20.00 3rd Qu.: 78.00 3rd Qu.:281.0 3rd Qu.:517.0
Max. :27.00 Max. :127.00 Max. :352.0 Max. :596.0
Mass.g. Temp.C.
Min. : 7 Min. :30.70
1st Qu.: 112 1st Qu.:35.40
Median : 1110 Median :37.00
Mean : 538070 Mean :36.52
3rd Qu.: 9500 3rd Qu.:38.00
Max. :62500000 Max. :40.10
plot(dtemp$ivy , dtemp$Temp.C.)
cor.test(dtemp$ivy , dtemp$Temp.C.)
Pearson's product-moment correlation
data: dtemp$ivy and dtemp$Temp.C.
t = -0.80579, df = 151, p-value = 0.4216
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.22180858 0.09422297
sample estimates:
cor
-0.06543346
No correlation with proportion of IVYWREL.
plot(dtemp$ivy , dtemp$Mass.g., log="y")
cor.test(dtemp$ivy , dtemp$Mass.g.)
Pearson's product-moment correlation
data: dtemp$ivy and dtemp$Mass.g.
t = 0.20981, df = 151, p-value = 0.8341
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.1419908 0.1752753
sample estimates:
cor
0.01707201
#sum(coa$co[1] * t(dtemp[1,3:22]))
#apply(dtemp, 1, function (x) {return (sum(coa$co[1] * t(x[2:21])))})
dtemp$axis1Coord <- apply(dtemp[,3:22], 1, function (x) {return (sum(coa$co[1] * t(x)))})
dtemp$axis2Coord <- apply(dtemp[,3:22], 1, function (x) {return (sum(coa$co[2] * t(x)))})
dtemp$axis3Coord <- apply(dtemp[,3:22], 1, function (x) {return (sum(coa$co[3] * t(x)))})
dtemp$axis1Coord <- sapply(dtemp$sp, function(z)coa$l1[which(d[,1]==z)[1],1])
dtemp$axis2Coord <- sapply(dtemp$sp, function(z)coa$l1[which(d[,1]==z)[1],2])
dtemp$axis3Coord <- sapply(dtemp$sp, function(z)coa$l1[which(d[,1]==z)[1],3])
plot(dtemp$axis1Coord , dtemp$Temp.C.)
cor.test(dtemp$axis1Coord , dtemp$Temp.C.)
Pearson's product-moment correlation
data: dtemp$axis1Coord and dtemp$Temp.C.
t = -1.6049, df = 151, p-value = 0.1106
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.28237861 0.02978706
sample estimates:
cor
-0.1295032
plot(dtemp$axis2Coord , dtemp$Temp.C.)
cor.test(dtemp$axis2Coord , dtemp$Temp.C.)
Pearson's product-moment correlation
data: dtemp$axis2Coord and dtemp$Temp.C.
t = -0.64599, df = 151, p-value = 0.5193
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.2094312 0.1070724
sample estimates:
cor
-0.05249771
plot(dtemp$axis3Coord , dtemp$Temp.C.)
cor.test(dtemp$axis3Coord , dtemp$Temp.C.)
Pearson's product-moment correlation
data: dtemp$axis3Coord and dtemp$Temp.C.
t = 1.296, df = 151, p-value = 0.1969
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.05470034 0.25925148
sample estimates:
cor
0.1048882
dReptilia<-read.table("reptiliaCompositions.csv", h=T, sep="\t")
dReptilia$tot <- rowSums(dReptilia[,3:22])
dReptilia$ivy <- (dReptilia$I + dReptilia$V + dReptilia$Y + dReptilia$W + dReptilia$R + dReptilia$E + dReptilia$L) / dReptilia$tot
summary(dReptilia)
sp
Abronia graminea : 1
Acanthosaura armata : 1
Achalinus meiguensis : 1
Achalinus spinalis : 1
Acrochordus granulatus : 1
Aeluroscalabotes felinus: 1
(Other) :294
tax
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Archelosauria, Archosauria, Crocodylia, Longirostres, Crocodylidae, Crocodylus : 11
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Lepidosauria, Squamata, Bifurcata, Unidentata, Episquamata, Toxicofera, Iguania, Acrodonta, Agamidae, Agaminae, Phrynocephalus : 10
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Lepidosauria, Squamata, Bifurcata, Unidentata, Episquamata, Toxicofera, Serpentes, Colubroidea, Dipsadidae, Hypsiglena : 10
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Lepidosauria, Squamata, Bifurcata, Unidentata, Episquamata, Toxicofera, Serpentes, Colubroidea, Viperidae, Crotalinae, Protobothrops: 10
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Archelosauria, Testudines, Cryptodira, Durocryptodira, Testudinoidea, Geoemydidae, Geoemydinae, Cuora : 9
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Archelosauria, Testudines, Cryptodira, Durocryptodira, Testudinoidea, Geoemydidae, Geoemydinae, Mauremys : 9
(Other) :241
A C D E
Min. :183.0 Min. :21.00 Min. :51.00 Min. : 75.00
1st Qu.:239.0 1st Qu.:28.00 1st Qu.:60.00 1st Qu.: 86.75
Median :251.0 Median :30.00 Median :63.00 Median : 90.00
Mean :260.2 Mean :30.29 Mean :63.02 Mean : 89.52
3rd Qu.:280.0 3rd Qu.:32.00 3rd Qu.:66.00 3rd Qu.: 93.00
Max. :391.0 Max. :41.00 Max. :77.00 Max. :101.00
F G H I
Min. :179.0 Min. :183.0 Min. : 81.0 Min. :216.0
1st Qu.:204.0 1st Qu.:199.0 1st Qu.: 99.0 1st Qu.:299.0
Median :213.0 Median :210.0 Median :103.0 Median :312.0
Mean :212.1 Mean :209.9 Mean :103.2 Mean :307.8
3rd Qu.:221.0 3rd Qu.:220.0 3rd Qu.:108.0 3rd Qu.:320.2
Max. :247.0 Max. :274.0 Max. :134.0 Max. :359.0
K L M N
Min. : 67.00 Min. :519.0 Min. :149.0 Min. :104.0
1st Qu.: 88.00 1st Qu.:585.0 1st Qu.:216.0 1st Qu.:136.0
Median : 94.00 Median :607.0 Median :242.0 Median :144.0
Mean : 96.55 Mean :610.9 Mean :240.7 Mean :143.3
3rd Qu.:104.00 3rd Qu.:638.2 3rd Qu.:257.0 3rd Qu.:152.0
Max. :135.00 Max. :769.0 Max. :316.0 Max. :175.0
P Q R S
Min. :182.0 Min. : 80.00 Min. :58.00 Min. :196.0
1st Qu.:200.0 1st Qu.: 94.00 1st Qu.:62.00 1st Qu.:257.0
Median :206.0 Median : 98.00 Median :68.00 Median :268.0
Mean :206.2 Mean : 98.63 Mean :67.04 Mean :265.0
3rd Qu.:212.0 3rd Qu.:103.00 3rd Qu.:71.00 3rd Qu.:276.2
Max. :258.0 Max. :114.00 Max. :88.00 Max. :323.0
T V W Y
Min. :269.0 Min. :123.0 Min. : 92.0 Min. : 88.0
1st Qu.:352.0 1st Qu.:152.0 1st Qu.: 98.0 1st Qu.:109.0
Median :388.5 Median :160.0 Median :101.0 Median :114.0
Mean :386.8 Mean :160.8 Mean :102.6 Mean :114.6
3rd Qu.:420.0 3rd Qu.:170.0 3rd Qu.:107.0 3rd Qu.:120.0
Max. :505.0 Max. :209.0 Max. :120.0 Max. :138.0
X tot ivy
Mode:logical Min. :3182 Min. :0.3560
NA's:300 1st Qu.:3755 1st Qu.:0.3791
Median :3770 Median :0.3874
Mean :3769 Mean :0.3855
3rd Qu.:3782 3rd Qu.:0.3920
Max. :4317 Max. :0.4051
dAmphibia<-read.table("amphibiaCompositions.csv", h=T, sep="\t")
dAmphibia$tot <- rowSums(dAmphibia[,3:22])
dAmphibia$ivy <- (dAmphibia$I + dAmphibia$V + dAmphibia$Y + dAmphibia$W + dAmphibia$R + dAmphibia$E + dAmphibia$L) / dAmphibia$tot
summary(dAmphibia)
sp
Alytes obstetricans pertinax: 1
Ambystoma andersoni : 1
Ambystoma barbouri : 1
Ambystoma bishopi : 1
Ambystoma californiense : 1
Ambystoma dumerilii : 1
(Other) :230
tax
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Anura, Neobatrachia, Ranoidea, Ranidae, Pelophylax : 13
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Caudata, Cryptobranchoidea, Hynobiidae, Hynobius, Hynobius : 11
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Caudata, Salamandroidea, Ambystomatidae, Ambystoma : 10
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Anura, Neobatrachia, Ranoidea, Ranidae, Rana, Rana : 8
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Caudata, Salamandroidea, Salamandridae, Pleurodelinae, Triturus: 7
Eukaryota, Metazoa, Chordata, Craniata, Vertebrata, Euteleostomi, Amphibia, Batrachia, Anura, Bombinatoridae, Bombina : 6
(Other) :181
A C D E
Min. :213.0 Min. :23.00 Min. :58.00 Min. : 81.00
1st Qu.:259.0 1st Qu.:28.00 1st Qu.:66.00 1st Qu.: 90.00
Median :287.0 Median :29.00 Median :69.00 Median : 93.00
Mean :287.2 Mean :29.39 Mean :69.48 Mean : 93.04
3rd Qu.:317.0 3rd Qu.:31.00 3rd Qu.:72.00 3rd Qu.: 97.00
Max. :385.0 Max. :37.00 Max. :93.00 Max. :105.00
F G H I
Min. :202.0 Min. :189.0 Min. : 82.00 Min. :266.0
1st Qu.:232.8 1st Qu.:219.0 1st Qu.: 92.00 1st Qu.:309.0
Median :250.0 Median :222.0 Median : 96.00 Median :320.0
Mean :248.1 Mean :222.1 Mean : 95.99 Mean :321.6
3rd Qu.:261.2 3rd Qu.:225.0 3rd Qu.: 99.00 3rd Qu.:337.0
Max. :318.0 Max. :255.0 Max. :125.00 Max. :380.0
K L M N
Min. : 73.00 Min. :543.0 Min. :144.0 Min. :117.0
1st Qu.: 84.00 1st Qu.:597.8 1st Qu.:172.0 1st Qu.:129.0
Median : 87.00 Median :609.0 Median :220.0 Median :138.5
Mean : 86.42 Mean :608.4 Mean :212.2 Mean :141.4
3rd Qu.: 89.00 3rd Qu.:621.0 3rd Qu.:250.0 3rd Qu.:155.0
Max. :103.00 Max. :718.0 Max. :298.0 Max. :170.0
P Q R S
Min. :184 Min. : 77.00 Min. :63.00 Min. :229.0
1st Qu.:197 1st Qu.: 89.00 1st Qu.:69.75 1st Qu.:269.0
Median :202 Median : 93.00 Median :71.00 Median :282.0
Mean :202 Mean : 93.39 Mean :71.32 Mean :281.6
3rd Qu.:207 3rd Qu.: 98.00 3rd Qu.:73.00 3rd Qu.:293.0
Max. :245 Max. :114.00 Max. :94.00 Max. :335.0
T V W Y
Min. :246.0 Min. :146.0 Min. :102.0 Min. : 99.0
1st Qu.:280.0 1st Qu.:173.0 1st Qu.:108.0 1st Qu.:108.0
Median :295.0 Median :186.0 Median :110.0 Median :113.0
Mean :298.5 Mean :185.4 Mean :110.4 Mean :113.6
3rd Qu.:312.2 3rd Qu.:197.0 3rd Qu.:113.0 3rd Qu.:118.0
Max. :384.0 Max. :243.0 Max. :126.0 Max. :132.0
X tot ivy
Mode:logical Min. :3689 Min. :0.3815
NA's:236 1st Qu.:3757 1st Qu.:0.3945
Median :3768 Median :0.3995
Mean :3771 Mean :0.3987
3rd Qu.:3783 3rd Qu.:0.4035
Max. :4370 Max. :0.4205
boxplot(d$ivy, dReptilia$ivy, dAmphibia$ivy, names=c("Mammalia", "Reptilia", "Amphibia"), ylab="% IVYWREL")
t.test(d$ivy, dReptilia$ivy, paired=F)
Welch Two Sample t-test
data: d$ivy and dReptilia$ivy
t = 22.559, df = 336.86, p-value < 2.2e-16
alternative hypothesis: true difference in means is not equal to 0
95 percent confidence interval:
0.01276177 0.01519986
sample estimates:
mean of x mean of y
0.3995051 0.3855242
t.test(d$ivy, dAmphibia$ivy, paired=F)
Welch Two Sample t-test
data: d$ivy and dAmphibia$ivy
t = 1.8382, df = 302.6, p-value = 0.06701
alternative hypothesis: true difference in means is not equal to 0
95 percent confidence interval:
-5.587812e-05 1.641059e-03
sample estimates:
mean of x mean of y
0.3995051 0.3987125
toExportMam <- cbind(as.character(d$sp), d$ivy, rep("Mammalia", length(d$sp)))
colnames(toExportMam) <- c("sp", "ivy", "type")
toExportRept <- cbind (as.character(dReptilia$sp), dReptilia$ivy, rep("Reptilia", length(dReptilia$sp)))
colnames(toExportRept) <- c("sp", "ivy", "type")
# Special treatment for Amphibia
typeAmph <- sapply(as.character(dAmphibia$tax), function(x) {return (strsplit(x, split=", ")[[1]][9][[1]])})
y<-t(data.frame(lapply(typeAmph, type.convert), stringsAsFactors=FALSE))
typeAmph <- y[,1]
toExportAmph <- cbind (as.character(dAmphibia$sp), dAmphibia$ivy, typeAmph)
colnames(toExportAmph) <- c("sp", "ivy", "type")
toExport <- rbind(toExportMam, toExportRept, toExportAmph)
colnames(toExport) <- c("sp", "ivy", "type")
write.table(toExport,file="speciesIvyMamReptAmph.csv", sep="\t", quote=F, row.names=F, col.names=T)
http://www.pnas.org/content/106/22/8986
hist(dReptilia$ivy, n=50)
## Aguamidae:
abline(v=dReptilia$ivy[dReptilia$sp =="Pogona vitticeps"], col="blue")
abline(v=dReptilia$ivy[dReptilia$sp =="Xenagama taylori"], col="blue")
## Blind snakes
# Ramphotyphlops:
abline(v=dReptilia$ivy[dReptilia$sp =="Indotyphlops braminus"], col="green")
# Leptotyphlops:
abline(v=dReptilia$ivy[dReptilia$sp =="Rena humilis"], col="green")
# Typhlops mirus:
abline(v=dReptilia$ivy[dReptilia$sp =="Amerotyphlops reticulatus"], col="green")
# True snakes
abline(v=dReptilia$ivy[dReptilia$sp =="Anilius scytale"], col="darkgreen")
abline(v=dReptilia$ivy[dReptilia$sp =="Tropidophis haetianus"], col="darkgreen")
abline(v=dReptilia$ivy[dReptilia$sp =="Cylindrophis ruffus"], col="darkgreen")
# Iguanidae:
abline(v=dReptilia$ivy[dReptilia$sp =="Iguana iguana"], col="darkblue", lty=2)
abline(v=dReptilia$ivy[dReptilia$sp =="Anolis carolinensis"], col="darkblue", lty=2)
abline(v=dReptilia$ivy[dReptilia$sp =="Sceloporus occidentalis"], col="darkblue", lty=2)
# Out of curiosity, a long lived tortoise:
abline(v=dReptilia$ivy[dReptilia$sp =="Aldabrachelys gigantea"], col="red", lty=2)
# And the tuatara (Sphenodon punctatus)
abline(v=dReptilia$ivy[dReptilia$sp =="Sphenodon punctatus"], col="orange", lty=2)
Then in ampĥibians the olm (Proteus anguinus, http://www.viralnova.com/animals-dont-eat/) should have a very low ivy content.
hist(dAmphibia$ivy, n=50)
## olm, Proteus anguinus:
abline(v=dAmphibia$ivy[dAmphibia$sp =="Proteus anguinus"], col="blue", lwd=1)
## Wood frog, which can hibernate and freeze (Rana sylvatica aka Lithobates sylvaticus):
abline(v=dAmphibia$ivy[dAmphibia$sp =="Rana sylvatica"], col="green", lwd=1)
white <- read.table("dataWhiteBiolLett2006/data.txt", h=T, sep="\t", colClasses = c("character", "numeric", "numeric", "numeric"), strip.white=TRUE)
summary(white)
sp mass temperature
Length:2824 Min. : 0.03 Min. : 1.00
Class :character 1st Qu.: 9.30 1st Qu.:15.00
Mode :character Median : 43.00 Median :20.00
Mean : 625.37 Mean :22.39
3rd Qu.: 300.00 3rd Qu.:30.50
Max. :137900.00 Max. :45.00
mr
Min. : 0.004
1st Qu.: 0.816
Median : 4.457
Mean : 100.740
3rd Qu.: 31.931
Max. :23994.600
d$sp <- as.character(d$sp)
dAmphibia$sp <- as.character(dAmphibia$sp)
dReptilia$sp <- as.character(dReptilia$sp)
dwhite <- merge(d, white, by.x="sp", by.y="sp")
dim(dwhite)
[1] 107 28
dRepwhite <- merge(dReptilia, white, by.x="sp", by.y="sp")
dim(dRepwhite)
[1] 57 28
dAmpwhite <- merge(dAmphibia, white, by.x="sp", by.y="sp")
dim(dAmpwhite)
[1] 94 28
plot(dwhite$ivy, dwhite$mr, pch=20, col=rgb(0,0,0,0.6), log="y")
cor.test(dwhite$ivy, dwhite$mr)
Pearson's product-moment correlation
data: dwhite$ivy and dwhite$mr
t = -0.66347, df = 105, p-value = 0.5085
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.2513875 0.1268009
sample estimates:
cor
-0.06461297
plot(dAmpwhite$ivy, dAmpwhite$mr, pch=20, col=rgb(0,1,0,0.6), log="y")
cor.test(dAmpwhite$ivy, dAmpwhite$mr)
Pearson's product-moment correlation
data: dAmpwhite$ivy and dAmpwhite$mr
t = 5.3768, df = 92, p-value = 5.714e-07
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.3178566 0.6292546
sample estimates:
cor
0.4889816
plot(dRepwhite$ivy, dRepwhite$mr, pch=20, col=rgb(1,0,0,0.6), log="y")
cor.test(dRepwhite$ivy, dRepwhite$mr)
Pearson's product-moment correlation
data: dRepwhite$ivy and dRepwhite$mr
t = -4.2903, df = 55, p-value = 7.277e-05
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.6734464 -0.2762232
sample estimates:
cor
-0.5007495
plot(dwhite$ivy, dwhite$temperature, pch=20, col=rgb(0,0,0,0.6), log="y")
cor.test(dwhite$ivy, dwhite$temperature)
Pearson's product-moment correlation
data: dwhite$ivy and dwhite$temperature
t = -0.80396, df = 105, p-value = 0.4232
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.2641533 0.1133237
sample estimates:
cor
-0.07821761
plot(dAmpwhite$ivy, dAmpwhite$temperature, pch=20, col=rgb(0,0,0,0.6), log="y")
cor.test(dAmpwhite$ivy, dAmpwhite$temperature)
Pearson's product-moment correlation
data: dAmpwhite$ivy and dAmpwhite$temperature
t = 2.167, df = 92, p-value = 0.03282
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.01858779 0.40491175
sample estimates:
cor
0.2203748
plot(dRepwhite$ivy, dRepwhite$temperature, pch=20, col=rgb(1,0,0,0.6))
cor.test(dRepwhite$ivy, dRepwhite$temperature)
Pearson's product-moment correlation
data: dRepwhite$ivy and dRepwhite$temperature
t = -0.10244, df = 55, p-value = 0.9188
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.2733956 0.2476470
sample estimates:
cor
-0.01381193
plot(dwhite$ivy, dwhite$mass, pch=20, col=rgb(0,0,0,0.6), log="y")
cor.test(dwhite$ivy, dwhite$mass)
Pearson's product-moment correlation
data: dwhite$ivy and dwhite$mass
t = -0.25366, df = 105, p-value = 0.8003
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.2136017 0.1658910
sample estimates:
cor
-0.02474688
plot(dAmpwhite$ivy, dAmpwhite$mass, pch=20, col=rgb(0,0,0,0.6), log="y")
cor.test(dAmpwhite$ivy, dAmpwhite$mass)
Pearson's product-moment correlation
data: dAmpwhite$ivy and dAmpwhite$mass
t = 5.7554, df = 92, p-value = 1.127e-07
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.3482034 0.6494333
sample estimates:
cor
0.51452
plot(dRepwhite$ivy, dRepwhite$mass, pch=20, col=rgb(1,0,0,0.6), log="y")
cor.test(dRepwhite$ivy, dRepwhite$mass)
Pearson's product-moment correlation
data: dRepwhite$ivy and dRepwhite$mass
t = -7.2259, df = 55, p-value = 1.608e-09
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
-0.8109617 -0.5344809
sample estimates:
cor
-0.6978589
ivywhite <- rbind (dwhite, dAmpwhite, dRepwhite)
coaw <- dudi.coa(ivywhite[,3:22], scan = F, nf =6)
ivywhite$axis1Coord <- sapply(ivywhite$sp, function(z)coaw$l1[which(ivywhite[,1]==z)[1],1])
ivywhite$axis2Coord <- sapply(ivywhite$sp, function(z)coaw$l1[which(ivywhite[,1]==z)[1],2])
ivywhite$axis3Coord <- sapply(ivywhite$sp, function(z)coaw$l1[which(ivywhite[,1]==z)[1],3])
plot(ivywhite$axis1Coord , ivywhite$temperature)
cor.test(ivywhite$axis1Coord , ivywhite$temperature)
Pearson's product-moment correlation
data: ivywhite$axis1Coord and ivywhite$temperature
t = 4.3178, df = 256, p-value = 2.255e-05
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.1429643 0.3708651
sample estimates:
cor
0.2605404
plot(ivywhite$axis2Coord , ivywhite$temperature)
cor.test(ivywhite$axis2Coord , ivywhite$temperature)
Pearson's product-moment correlation
data: ivywhite$axis2Coord and ivywhite$temperature
t = 4.144, df = 256, p-value = 4.642e-05
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.1326638 0.3617742
sample estimates:
cor
0.2507267
plot(ivywhite$axis3Coord , ivywhite$temperature, pch=20)
cor.test(ivywhite$axis3Coord , ivywhite$temperature)
Pearson's product-moment correlation
data: ivywhite$axis3Coord and ivywhite$temperature
t = 7.3487, df = 256, p-value = 2.685e-12
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.3111088 0.5133353
sample estimates:
cor
0.417376