Data$Area[j] = min(Data$Depth[j]/h, 1)*A  # The effective, i.e. "submerged" cone cross-sectional area [cm2]
}
Data$PR = Data$Load/(Data$Area*1e-4)*1e-6
# Delete unrealistic values (Load < 0)
Data=subset(Data,subset=(Data$Load>=0))
ColSet=c("green","black","darkgrey")
quartz(height=5.5,width=7)
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,0.30), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (MPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
Data$PR = Data$Load/(Data$Area*1e-4)*1e-3
# Delete unrealistic values (Load < 0)
Data=subset(Data,subset=(Data$Load>=0))
ColSet=c("green","black","darkgrey")
quartz(height=5.5,width=7)
quartz(height=5.5,width=7)
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (MPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
ColSet=c("darkgreen","black","darkgrey")
quartz(height=5.5,width=7)
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
ColSet=c("green","black","darkgrey")
quartz(height=5.5,width=7)
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
pdf(instron.pdf)
pdf('instron.pdf')
dev.off()
pdf('instron.pdf')
quartz(height=5.5,width=7)
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
dev.off()
quartz(height=5.5,width=7)
pdf('instron.pdf')
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
dev.off()
quartz(height=5.5,width=7)
pdf('PenetrationResistance.pdf')
for (i in 1:length(filenames)){
Set=subset(Data,subset=Data$Set==i)
if(i==1) plot(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],
ylim=c(0,300), type='p',cex=0.1,bty='n',
xlab="Depth (cm)", ylab="Penetration resistance (kPa)")
else points(Set$Depth,Set$PR, col=ColSet[ceil(i/3)],cex=0.1)
}
legend("topleft",legend=c('Algal-covered levee','Bare levee','Bare mudflat'),
col=cbind(ColSet,ColSet,ColSet), bty='n', lty=1 )
dev.off()       # Save the figure
?aggregate
TestData=aggregate(x=list(PR=Data$PR),by=list(Location=Data$Location,Block=Data$Block),
FUN=median)
TestData
?lm
# Fitting a linear model
M1=lm(PR~Location+(1|Block), data=TestData)
print(anova(M1))
quartz(width=7,height=5)
# A plot for normality
qqnorm(resid(M1)); qqline(resid(M1), col = 2,lwd=2,lty=2)
# Testing for normality of the residuals
print(shapiro.test(resid(M1)))
?shapiro.test
shapiro.test(rnorm(100, mean = 5, sd = 3))
shapiro.test(runif(100, min = 2, max = 4))
shapiro.test(rnorm(100, mean = 5, sd = 3))
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/Figure 3/AnalyzeInstron.R', echo=TRUE)
?pdf
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
?axis
axis(3); title(side=3, xlab="Penetration resistance (kPa)")
?title
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
axis(3); mtext(text="Penetration resistance (kPa)", side=3, line=2)
axis(3); mtext(text="Penetration resistance (kPa)", side=3, line=3)
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
?text
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 3/AnalyzeInstron.R')
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
#setwd(getwd()) # This per definition a pointless statement, set the dir to the current dit ;-)
setwd('~/Dropbox/Roeland/Paper 1/Stats/Figure 5')
Data = read.csv('MudPatternProfiles.csv')
?read.csv
Data = read.csv('MudPatternProfiles.csv',
col.names=c('Time', 'Z_201508', 'Z_201604', 'Z_201608', 'Z_201704', 'Z_201709', 'Z_201802')
)
Data
plot(Data$Time,Data$Z_201508,col='blue', type='l', bty='n')
plot(Data$Time,Data$Z_201508,col='blue', type='l', bty='n',
ylim=c(0,3), xlab='Time', ylab='Elevation')
plot(Data$Time,Data$Z_201508,col='blue', type='l', bty='n',
ylim=c(2,3), xlab='Time', ylab='Elevation')
Data[,1]
Data[,2]
for(i in 1:6) { lines(Data$Time,Data[,(i+1)], col=i)}
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/GetData.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/GetData.r')
Cols=1:7
plot(Data$Time,Data$Z_201508,col=Cols[1], type='l', bty='n',
ylim=c(2.6,3), xlab='Time', ylab='Elevation')
for(i in 1:6) { lines(Data$Time,Data[,(i+1)], col=Cols[i+1])}
Data = read.csv('MudPatternProfiles.csv', header=T)
Data
colnames(Data)
colnames(Data)[2:7]
Years=substr(Names,4,7)
Names=colnames(Data)[2:7]
Years=substr(Names,4,7)
Years
Years=substr(Names,3,6)
Months=substr(Names,7,8)
Months
Cols=c('red','magenta','green','black','magenta','red')
plot(Data$Time,Data$Z_201508,col=Cols[1], type='l', bty='n',
ylim=c(2.6,3), xlab='Time', ylab='Elevation')
for(i in 1:6) { lines(Data$Time,Data[,(i+1)], col=Cols[i+1])}
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
Data[,(i+1)]
?legend
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
legend("bottom", legend=Labels, col=Cols, bty='n', lty=1 )
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
grid(6,7)
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
?grid
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
source('~/Dropbox/Roeland/Paper 1/Stats/Figure 5/Figure 5.r')
getwd
getwd()
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd(getwd()) # This per definition a pointless statement, set the dir to the current dit ;-)
# setwd('~/Dropbox/Roeland/Paper 1/Stats/Figure 5')
on=1; off=0;
SAVE   = on # Whether or not to save output
Width  = 960
Height = 720
DPI    = 144
Data = read.table('../../output/DEMcrossSouth.txt')
Data = read.csv('MudPatternProfiles.csv', header=T)
Data = read.table('../../output/DEMcrossSouth.txt')
Data = t(Data)
View(Data)
Data = read.csv('MudPatternProfiles.csv', header=T)
Names=colnames(Data)[2:7]
Names
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
Names
# Names=colnames(Data)[2:7]
Years=substr(Names,5,6)
Years
Months=substr(Names,7,8)
Months
Labels=paste(Months,Years,sep='-')
Cols=c('blue','purple','green','black','magenta','red')
if(SAVE==on) {
pdf(file='Figure 5.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
} else quartz(height=Height/DPI, width=Width/DPI)
plot(Data$Time,Data$Z_201508,col=Cols[1], type='l', bty='n',
ylim=c(2.7,3),
xlab='Horizontal distance along the cross-section [m]',
ylab='Elevation above NAP [m]')
for(i in 2:6) { lines(Data$Time,Data[,(i+1)], col=Cols[i+1])}
grid()
legend("bottom", legend=Labels, col=Cols, bty='n', lty=1, horiz=T, cex=0.8 )
text(5, 2.73,'Month-Year:')
if(SAVE==on) dev.off()       # Finish saving figure
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd(getwd()) # This per definition a pointless statement, set the dir to the current dit ;-)
# setwd('~/Dropbox/Roeland/Paper 1/Stats/Figure 5')
on=1; off=0;
SAVE   = on # Whether or not to save output
Width  = 960
Height = 720
DPI    = 144
Data = read.table('../../output/DEMcrossSouth.txt')
Data = t(Data)
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
# Names=colnames(Data)[2:7]
Years=substr(Names,5,6)
Months=substr(Names,7,8)
Labels=paste(Months,Years,sep='-')
Cols=c('blue','purple','green','black','magenta','red')
if(SAVE==on) {
pdf(file='Figure 5.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
} else quartz(height=Height/DPI, width=Width/DPI)
plot(Data$Time,Data$Z_201508,col=Cols[1], type='l', bty='n',
ylim=c(2.7,3),
xlab='Horizontal distance along the cross-section [m]',
ylab='Elevation above NAP [m]')
View(Data)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd(getwd()) # This per definition a pointless statement, set the dir to the current dit ;-)
# setwd('~/Dropbox/Roeland/Paper 1/Stats/Figure 5')
on=1; off=0;
SAVE   = on # Whether or not to save output
Width  = 960
Height = 720
DPI    = 144
Data = read.table('../../output/DEMcrossSouth.txt')
Data = t(Data)
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
# Names=colnames(Data)[2:7]
Years=substr(Names,5,6)
Months=substr(Names,7,8)
Labels=paste(Months,Years,sep='-')
Cols=c('blue','purple','green','black','magenta','red')
if(SAVE==on) {
pdf(file='Figure 5.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
} else quartz(height=Height/DPI, width=Width/DPI)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd(getwd()) # This per definition a pointless statement, set the dir to the current dit ;-)
# setwd('~/Dropbox/Roeland/Paper 1/Stats/Figure 5')
on=1; off=0;
SAVE   = on # Whether or not to save output
Width  = 960
Height = 720
DPI    = 144
Data = read.table('../../output/DEMcrossSouth.txt')
Data = t(Data)
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
# Names=colnames(Data)[2:7]
Years=substr(Names,5,6)
Months=substr(Names,7,8)
Labels=paste(Months,Years,sep='-')
Cols=c('blue','magenta','green','black','cyan','red')
if(SAVE==on) {
pdf(file='Figure 5.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
} else quartz(height=Height/DPI, width=Width/DPI)
plot(Data[,1],Data[,2],col=Cols[1], type='l', bty='n',
ylim=c(2.7,2.95),
xlab='Horizontal distance along the cross-section [m]',
ylab='Elevation above NAP [m]')
for(i in 2:6) { lines(Data[,1],Data[,(i+1)], col=Cols[i+1])}
grid()
legend("bottom", legend=Labels, col=Cols, bty='n', lty=1, horiz=T, cex=0.8 )
text(5, 2.73,'Month-Year:')
if(SAVE==on) dev.off()       # Finish saving figure
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure 5/Figure 5.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
setwd("/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections")
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd("/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections")
# setwd(getwd())
on=1; off=0;
SAVE   = on # Whether or not to save output
FIG = A2; # 4 or A2 (4 = Fig.4 in main article; A2 = Appendix Fig. A2)
Width  = 960
Height = 720
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd("/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections")
# setwd(getwd())
on=1; off=0;
SAVE   = on # Whether or not to save output
FIG = 2; # 4 or 2 (4 = Fig.4 in main article; 2 = Appendix Fig. A2)
Width  = 960
Height = 720
DPI    = 144
if (FIG == 4) {
Data = read.table('../output/DEMcrossSouth.txt')
} else if(FIG == 2) {
Data = read.table('../output/DEMcrossNorth.txt')
}
Data = t(Data)
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
Years=substr(Names,5,6)
Months=substr(Names,7,8)
Labels=paste(Years,Months,sep='-')
Cols=c('blue','magenta','green','black','orange','red')
if(SAVE==on) {
Cols=c('blue','magenta','green','black','orange','red')
if(SAVE==on) {
if(FIG==4){
pdf(file='Figure4.pdf',   # Prepare to save figure
} else if(FIG == 2) {
pdf(file='FigureA2.pdf',   # Prepare to save figure
}
height=Height/DPI, width=Width/DPI,pointsize=12)
} else quartz(height=Height/DPI, width=Width/DPI)
plot(Data[,1],Data[,2],col=Cols[1], type='l', bty='n',
ylim=c(2.7,2.95),
xlab='Horizontal distance along the cross-section [m]',
ylab='Elevation above NAP [m]')
for(i in 2:6) { lines(Data[,1],Data[,(i+1)], col=Cols[i])}
grid()
legend("bottom", legend=Labels, col=Cols, bty='n', lty=1, horiz=T, cex=0.8 )
text(5, 2.73,'Year-Month:')
if(SAVE==on) dev.off()       # Finish saving figure
## Initialize workspace
remove(list=ls()) # Remove all variables from memory
graphics.off()    # Closes all figures
cat("\014")       # Clears the console
setwd("/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections")
# setwd(getwd())
on=1; off=0;
SAVE   = on # Whether or not to save output
FIG = 2; # 4 or A2 (4 = Fig.4 in main article; 2 = Appendix Fig. A2)
Width  = 960
Height = 720
DPI    = 144
if (FIG == 4) {
Data = read.table('../output/DEMcrossSouth.txt')
} else if(FIG == 2) {
Data = read.table('../output/DEMcrossNorth.txt')
}
Data = t(Data)
Names = c("Z_201508", "Z_201604", "Z_201608", "Z_201704", "Z_201709", "Z_201802")
Years=substr(Names,5,6)
Months=substr(Names,7,8)
Labels=paste(Years,Months,sep='-')
Cols=c('blue','magenta','green','black','orange','red')
if(SAVE==on) {
if(FIG == 4) {
pdf(file='Figure4.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
} else if (FIG == 2) {
pdf(file='FigureA2.pdf',   # Prepare to save figure
height=Height/DPI, width=Width/DPI,pointsize=12)
}
} else quartz(height=Height/DPI, width=Width/DPI)
plot(Data[,1],Data[,2],col=Cols[1], type='l', bty='n',
ylim=c(2.7,2.95),
xlab='Horizontal distance along the cross-section [m]',
ylab='Elevation above NAP [m]')
for(i in 2:6) { lines(Data[,1],Data[,(i+1)], col=Cols[i])}
grid()
legend("bottom", legend=Labels, col=Cols, bty='n', lty=1, horiz=T, cex=0.8 )
text(5, 2.73,'Year-Month:')
if(SAVE==on) dev.off()       # Finish saving figure
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('/Volumes/Seagate Backup Plus Drive/ART1_PSO_FINAL/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/DEM_VDVI_Comparison/DEM_CrossSections/Figure4.r', echo=TRUE)
cat("\014")       # Clears the console
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/DEM_VDVI_Comparison/DEM_CrossSections/Figure4_and_SI2.r', echo=TRUE)
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/DEM_VDVI_Comparison/DEM_CrossSections/Figure4_and_SI2.r', echo=TRUE)
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/Figure4_and_FigureSI2/Figure4_and_SI2.r', echo=TRUE)
source('~/Desktop/ART1_PSO_FINAL_SUBMISSION_20180527/Figure4_and_FigureSI2/Figure4_and_SI2.r', echo=TRUE)
