Difference between revisions of "Run GLM demo"

From Age of Water
Jump to: navigation, search
m (Installing required packages)
Line 17: Line 17:
  
 
If you get a success message, your task is complete!
 
If you get a success message, your task is complete!
 +
 +
===Troubleshooting===
 +
Mac Users: If you get a 'permission denied error' when running demo(glm), you must change the permission setting on the sim folder in terminal.
 +
<br>Example error:
 +
<code><pre> sh: /Library/Frameworks/R.framework/Versions/3.0/Resources/library/GLMr/extbin/macGLM/bin/glm: Permission denied </pre></code>
 +
 +
Steps
 +
# Open TERMINAL
 +
# Change directory folder to that listed in the error. (copy bold text, and change to match your personal file path)
 +
example:
 +
''MyLovley-MacBook-Pro:~ user$'' '''cd /Library/Frameworks/R.framework/Versions/3.0/Resources/library/GLMr/extbin/macGLM/bin'''
 +
# If you type '''ls''', you should see 10 files, one of which is titled 'glm'
 +
# Type
 +
<code><pre> chmod 755 glm </pre></code>
 +
# You should now be able to run demo(glm)
 +
 +
 
<!-- Do NOT Edit below this Line -->
 
<!-- Do NOT Edit below this Line -->
 
{{#set:
 
{{#set:

Revision as of 21:12, 21 October 2014


Installing required packages

For windows, OSX, or Linux use use the following command in R:

 install.packages("glmtools", 
    repos = c("http://gleon.github.com/", "http://cran.us.r-project.org", "http://usgs-r.github.com/"),
    dependencies = TRUE,
    type = "both")

You now have GLM (GLMr), R tools for GLM (glmtools), NetCDF file handlers (ncdf), and rLakeAnalyzer installed!!

Run GLM demo

library(GLMr)
demo(glm)

If you get a success message, your task is complete!

Troubleshooting

Mac Users: If you get a 'permission denied error' when running demo(glm), you must change the permission setting on the sim folder in terminal.
Example error:

 sh: /Library/Frameworks/R.framework/Versions/3.0/Resources/library/GLMr/extbin/macGLM/bin/glm: Permission denied 

Steps

  1. Open TERMINAL
  2. Change directory folder to that listed in the error. (copy bold text, and change to match your personal file path)

example: MyLovley-MacBook-Pro:~ user$ cd /Library/Frameworks/R.framework/Versions/3.0/Resources/library/GLMr/extbin/macGLM/bin

  1. If you type ls, you should see 10 files, one of which is titled 'glm'
  2. Type
 chmod 755 glm 
  1. You should now be able to run demo(glm)


Yandex.Metrica