Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HIDDEN
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
sPlot
HIDDEN
Commits
a5aecc7b
Commit
a5aecc7b
authored
4 years ago
by
Francesco Sabatini
Browse files
Options
Downloads
Patches
Plain Diff
Aligned to new results
parent
76c01596
No related branches found
No related tags found
No related merge requests found
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
00_Mesobromion_DataPreparation.R
+27
-27
27 additions, 27 deletions
00_Mesobromion_DataPreparation.R
02_Mesobromion_ExamineOutput.R
+170
-58
170 additions, 58 deletions
02_Mesobromion_ExamineOutput.R
with
197 additions
and
85 deletions
00_Mesobromion_DataPreparation.R
+
27
−
27
View file @
a5aecc7b
...
@@ -140,7 +140,7 @@ species <- env %>%
...
@@ -140,7 +140,7 @@ species <- env %>%
#dplyr::select(traits$species0)
#dplyr::select(traits$species0)
dim
(
species
)
# [1] 5810 873
dim
(
species
)
# [1] 5810 873
### 3.1 Subset plots based on trait coverage ####
releve08trait
<-
species
%>%
releve08trait
<-
species
%>%
rownames_to_column
(
"RELEVE_NR"
)
%>%
rownames_to_column
(
"RELEVE_NR"
)
%>%
reshape2
::
melt
(
.id
=
"RELEVE_NR"
)
%>%
reshape2
::
melt
(
.id
=
"RELEVE_NR"
)
%>%
...
@@ -358,7 +358,7 @@ traits %>%
...
@@ -358,7 +358,7 @@ traits %>%
source
(
"01b_MesobromionCluster.R"
)
source
(
"01b_MesobromionCluster.R"
)
#### 1. Traits individually significant for COVER data#### na.exclude=T ########
#### 1. Traits individually significant for COVER data#### na.exclude=T ########
traits
<-
read_delim
(
"_data/Mesobromion/traits.v2.10perc.txt"
,
delim
=
"\t"
)
traits
<-
read_delim
(
"_data/Mesobromion/traits.v2.10perc.txt"
,
delim
=
"\t"
)
myfilelist
<-
list.files
(
path
=
"_derived/Mesobromion/Cover"
,
pattern
=
"HIDDENcov-nona2_[0-9]+_.RData"
,
full.names
=
T
)
myfilelist
<-
list.files
(
path
=
"_derived/Mesobromion/Cover
/onebyone
"
,
pattern
=
"HIDDENcov-nona2_[0-9]+_.RData"
,
full.names
=
T
)
dataFiles
=
purrr
::
map
(
myfilelist
,
function
(
x
){
get
(
load
(
x
))})
dataFiles
=
purrr
::
map
(
myfilelist
,
function
(
x
){
get
(
load
(
x
))})
corXY
=
bind_rows
(
dataFiles
)
%>%
corXY
=
bind_rows
(
dataFiles
)
%>%
as_tibble
()
%>%
as_tibble
()
%>%
...
@@ -401,17 +401,17 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.cov.sign.txt",
...
@@ -401,17 +401,17 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.cov.sign.txt",
8 35 0.241 0.128 0.217 0.289 0.970 999 TRUE FALSE 1 LeafP "
8 35 0.241 0.128 0.217 0.289 0.970 999 TRUE FALSE 1 LeafP "
### COV - NONA2 - modified Matrix.x to deal with NAs INSIDE the analysis
### COV - NONA2 - modified Matrix.x to deal with NAs INSIDE the analysis
"# A tibble:
53
x 11
"# A tibble:
48
x 11
Trait.comb Coef.obs Coef.perm q025 q975 greater.than.perm n sign_plus sign_minus ntraits trait.name
Trait.comb Coef.obs Coef.perm q025 q975 greater.than.perm n sign_plus sign_minus ntraits trait.name
<chr> <dbl> <dbl> <dbl> <dbl> <dbl> <int> <lgl> <lgl> <int> <fct>
<chr> <dbl> <dbl> <dbl> <dbl> <dbl> <int> <lgl> <lgl> <int> <fct>
1 3
6
0.304 0.
151
0.280 0.35
5
0.99
8
999 TRUE FALSE 1 PlantHeight
1 3
1
0.304 0.
0805
0.280 0.35
7
0.99
4
999 TRUE FALSE 1 PlantHeight
2 5
0
0.292 0.
0641
0.26
5
0.34
6
0.9
88
999 TRUE FALSE 1 BL_ANAT
2
4
5 0.292 0.
205
0.26
3
0.34
4
0.9
90
999 TRUE FALSE 1 BL_ANAT
3 2 0.262 0.
0633
0.2
2
3 0.31
2
0.98
9
999 TRUE FALSE 1 LEB_F_Nanophanerophyt
3 2 0.262 0.
126
0.23
0
0.31
7
0.98
8
999 TRUE FALSE 1 LEB_F_Nanophanerophyt
4
30
0.259 0.1
4
5 0.2
30
0.307 0.97
6
999 TRUE FALSE 1 BL_DAU
4
25
0.259 0.1
2
5 0.2
27
0.307 0.97
4
999 TRUE FALSE 1 BL_DAU
5
20
0.251 0.
109
0.20
5
0.32
4
0.98
4
999 TRUE FALSE 1 V_VER_Fragmentation
5
16
0.251 0.
0718
0.20
4
0.32
6
0.98
3
999 TRUE FALSE 1 V_VER_Fragmentation
6
3
2 0.247 0.
238
0.22
4
0.297 0.96
4
999 TRUE FALSE 1 SLA
6 2
7
0.247 0.
0761
0.22
7
0.297 0.96
5
999 TRUE FALSE 1 SLA
7 3
5
0.241 0.20
0
0.
2
21 0.28
7
0.9
6
5 999 TRUE FALSE 1 LeafP
7 3
0
0.241 0.20
7
0.21
3
0.28
6
0.95
1
999 TRUE FALSE 1 LeafP
8 4
9
0.238 0.
0786
0.21
7
0.28
6
0.9
65
999 TRUE FALSE 1 STRAT_T "
8 4
4
0.238 0.
187
0.21
3
0.28
5
0.9
71
999 TRUE FALSE 1 STRAT_T
"
### COV - without deleting NAs
### COV - without deleting NAs
"# A tibble: 53 x 11
"# A tibble: 53 x 11
...
@@ -423,7 +423,7 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.cov.sign.txt",
...
@@ -423,7 +423,7 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.cov.sign.txt",
#### 2. Traits individually significant for Presence|absence data####
#### 2. Traits individually significant for Presence|absence data####
traits
<-
read_delim
(
"_data/Mesobromion/traits.v2.10perc.txt"
,
delim
=
"\t"
)
traits
<-
read_delim
(
"_data/Mesobromion/traits.v2.10perc.txt"
,
delim
=
"\t"
)
myfilelist
<-
list.files
(
path
=
"_derived/Mesobromion/PresAbs"
,
pattern
=
"HIDDENpa-nona2_[0-9]+_.RData"
,
full.names
=
T
)
myfilelist
<-
list.files
(
path
=
"_derived/Mesobromion/PresAbs
/onebyone
"
,
pattern
=
"HIDDENpa-nona2_[0-9]+_.RData"
,
full.names
=
T
)
dataFiles
=
purrr
::
map
(
myfilelist
,
function
(
x
){
get
(
load
(
x
))})
dataFiles
=
purrr
::
map
(
myfilelist
,
function
(
x
){
get
(
load
(
x
))})
corXY
=
bind_rows
(
dataFiles
)
%>%
corXY
=
bind_rows
(
dataFiles
)
%>%
as_tibble
()
as_tibble
()
...
@@ -466,22 +466,22 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.pa.sign.txt",
...
@@ -466,22 +466,22 @@ write_delim(traits.sign, path="_data/Mesobromion/traits.v2.10perc.pa.sign.txt",
## Pres Abs NoNa2 -modified Matrix.x to deal with NAs INSIDE the analysis
## Pres Abs NoNa2 -modified Matrix.x to deal with NAs INSIDE the analysis
## Data Filled up by HB used in this analysis
## Data Filled up by HB used in this analysis
" Trait.comb Coef.obs Coef.perm q025 q975 greater.than.perm n sign_plus sign_minus ntraits trait.name
"# A tibble: 48 x 11
Trait.comb Coef.obs Coef.perm q025 q975 greater.than.perm n sign_plus sign_minus ntraits trait.name
<chr> <dbl> <dbl> <dbl> <dbl> <dbl> <int> <lgl> <lgl> <int> <fct>
<chr> <dbl> <dbl> <dbl> <dbl> <dbl> <int> <lgl> <lgl> <int> <fct>
1 50 0.311 0.0624 0.284 0.362 0.996 999 TRUE FALSE 1 BL_ANAT
1 45 0.311 0.139 0.282 0.364 0.999 999 TRUE FALSE 1 BL_ANAT
2 36 0.307 0.190 0.279 0.359 0.995 999 TRUE FALSE 1 PlantHeight
2 31 0.307 0.160 0.279 0.358 0.999 999 TRUE FALSE 1 PlantHeight
3 2 0.295 0.105 0.254 0.346 0.997 999 TRUE FALSE 1 LEB_F_Nanophanerophyt
3 2 0.295 0.123 0.256 0.347 0.994 999 TRUE FALSE 1 LEB_F_Nanophanerophyt
4 30 0.260 0.124 0.229 0.312 0.991 999 TRUE FALSE 1 BL_DAU
4 25 0.260 0.0982 0.231 0.307 0.983 999 TRUE FALSE 1 BL_DAU
5 32 0.260 0.243 0.237 0.305 0.987 999 TRUE FALSE 1 SLA
5 27 0.260 0.0963 0.237 0.305 0.984 999 TRUE FALSE 1 SLA
6 35 0.253 0.131 0.230 0.299 0.983 999 TRUE FALSE 1 LeafP
6 30 0.253 0.158 0.229 0.300 0.987 999 TRUE FALSE 1 LeafP
7 33 0.240 0.0910 0.211 0.296 0.979 999 TRUE FALSE 1 LeafC.perdrymass
7 28 0.240 0.0705 0.212 0.295 0.980 999 TRUE FALSE 1 LeafC.perdrymass
8 49 0.240 0.0954 0.212 0.287 0.975 999 TRUE FALSE 1 STRAT_T
8 44 0.240 0.0618 0.213 0.293 0.981 999 TRUE FALSE 1 STRAT_T
9 34 0.233 0.294 0.210 0.281 0.963 999 TRUE FALSE 1 LeafN
9 29 0.233 0.0978 0.210 0.285 0.966 999 TRUE FALSE 1 LeafN
10 38 0.228 0.0907 0.203 0.278 0.958 999 TRUE FALSE 1 Seed.length
10 33 0.228 0.183 0.205 0.275 0.968 999 TRUE FALSE 1 Seed.length
11 39 0.226 0.106 0.198 0.282 0.963 999 TRUE FALSE 1 LDMC
11 34 0.226 0.0736 0.196 0.281 0.965 999 TRUE FALSE 1 LDMC
12 5 0.226 0.103 0.192 0.281 0.975 999 TRUE FALSE 1 LEB_F_Hemiphanerophyt
12 5 0.226 0.113 0.190 0.283 0.975 999 TRUE FALSE 1 LEB_F_Hemiphanerophyt
13 1 0.202 0.0560 0.170 0.248 0.953 999 TRUE FALSE 1 LEB_F_Makrophanerophyt
13 40 0.209 0.128 0.185 0.259 0.957 999 TRUE FALSE 1 Disp.unit.leng "
14 9 0.196 0.127 0.162 0.249 0.954 999 TRUE FALSE 1 LEB_F_Chamaephyt "
## Pres Abs - Without excluding species with NA in traits
## Pres Abs - Without excluding species with NA in traits
...
...
This diff is collapsed.
Click to expand it.
02_Mesobromion_ExamineOutput.R
+
170
−
58
View file @
a5aecc7b
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment