Skip to content

Instantly share code, notes, and snippets.

@feherCat
Created June 23, 2017 20:41
Show Gist options
  • Save feherCat/e23b2b6197db38a06035b2a163c211f9 to your computer and use it in GitHub Desktop.
Save feherCat/e23b2b6197db38a06035b2a163c211f9 to your computer and use it in GitHub Desktop.
Cumulative elevation trends
---------------------------
### SH3 deep - including all data points (pre & post Wilma)
``` r
DCSET_all <- lm(Site_avg~Days, data=subset(SH3, Type=="Deep_CU"))
```
##
## Call:
## lm(formula = Site_avg ~ Days, data = subset(SH3, Type == "Deep_CU"))
##
## Residuals:
## Min 1Q Median 3Q Max
## -20.3496 -3.4127 -0.7529 2.3280 26.7322
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 9.6417345 2.0161167 4.782 2.15e-05 ***
## Days 0.0082418 0.0008241 10.001 1.12e-12 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 8.376 on 42 degrees of freedom
## Multiple R-squared: 0.7043, Adjusted R-squared: 0.6972
## F-statistic: 100 on 1 and 42 DF, p-value: 1.118e-12
##### rate of elevation change for deep = 3.01 mm/yr
``` r
coef(DCSET_all)["Days"] * 365.25
```
## Days
## 3.010314
------------------------------------------------------------------------
### SH3 shallow - including all data points (pre & post Wilma)
``` r
SCSET_all <- lm(Site_avg~Days, data=subset(SH3, Type="Shallow_CU"))
```
##
## Call:
## lm(formula = Site_avg ~ Days, data = subset(SH3, Type = "Shallow_CU"))
##
## Residuals:
## Min 1Q Median 3Q Max
## -42.221 -13.955 -1.929 9.733 65.137
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 3.1016718 1.5934502 1.947 0.0524 .
## Days 0.0049936 0.0006328 7.892 3.79e-14 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 18.82 on 353 degrees of freedom
## Multiple R-squared: 0.15, Adjusted R-squared: 0.1476
## F-statistic: 62.28 on 1 and 353 DF, p-value: 3.79e-14
##### rate of elevation change for shallow = 1.8 mm/yr
``` r
coef(SCSET_all)["Days"] * 365.25
```
## Days
## 1.823916
#### Cumulative Elevation - all dates
![](SH3_files/figure-markdown_github/unnamed-chunk-11-1.png)

Cumulative elevation trends

SH3 deep - including all data points (pre & post Wilma)

DCSET_all <- lm(Site_avg~Days, data=subset(SH3, Type=="Deep_CU"))
## 
## Call:
## lm(formula = Site_avg ~ Days, data = subset(SH3, Type == "Deep_CU"))
## 
## Residuals:
##      Min       1Q   Median       3Q      Max 
## -20.3496  -3.4127  -0.7529   2.3280  26.7322 
## 
## Coefficients:
##              Estimate Std. Error t value Pr(>|t|)    
## (Intercept) 9.6417345  2.0161167   4.782 2.15e-05 ***
## Days        0.0082418  0.0008241  10.001 1.12e-12 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 8.376 on 42 degrees of freedom
## Multiple R-squared:  0.7043, Adjusted R-squared:  0.6972 
## F-statistic:   100 on 1 and 42 DF,  p-value: 1.118e-12
rate of elevation change for deep = 3.01 mm/yr
coef(DCSET_all)["Days"] * 365.25
##     Days 
## 3.010314

SH3 shallow - including all data points (pre & post Wilma)

SCSET_all <- lm(Site_avg~Days, data=subset(SH3, Type="Shallow_CU"))
## 
## Call:
## lm(formula = Site_avg ~ Days, data = subset(SH3, Type = "Shallow_CU"))
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -42.221 -13.955  -1.929   9.733  65.137 
## 
## Coefficients:
##              Estimate Std. Error t value Pr(>|t|)    
## (Intercept) 3.1016718  1.5934502   1.947   0.0524 .  
## Days        0.0049936  0.0006328   7.892 3.79e-14 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 18.82 on 353 degrees of freedom
## Multiple R-squared:   0.15,  Adjusted R-squared:  0.1476 
## F-statistic: 62.28 on 1 and 353 DF,  p-value: 3.79e-14
rate of elevation change for shallow = 1.8 mm/yr
coef(SCSET_all)["Days"] * 365.25
##     Days 
## 1.823916

Cumulative Elevation - all dates

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment