-
Notifications
You must be signed in to change notification settings - Fork 1
/
run.R
80 lines (62 loc) · 1.61 KB
/
run.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# path = "/Users/tischi/Documents/HTM_Explorer/";setwd(path);source("run.R");
if (!require("gWidgets")) {
install.packages("gWidgets")
library(gWidgets)
}
if (!require("gWidgetstcltk")) {
install.packages("gWidgetstcltk")
library(gWidgetstcltk)
}
if (!require("markdown")) {
install.packages("markdown")
library(markdown)
}
if (!require("plyr")) {
install.packages("plyr")
library(plyr)
}
if (!require("RColorBrewer")) {
install.packages("RColorBrewer")
library(RColorBrewer)
}
if (!require("raster")) {
install.packages("raster")
library(raster)
}
#if (!require("plotly")) {
# install.packages("plotly")
# library(plotly)
#}
#if (!require("shiny")) {
# install.packages("shiny")
# library(plotly)
#}
#options(warn = 2)
## source code
#setwd(path);source("install.R");
source("classes.R")
# Forcefully make a new htm object
htm <<- htmMake()
#print("Checking htm object...")
#if(exists("htm")) {
# print(" Found htm object; left it as it was; only restarting the GUI.")
#} else {
# print(" No htm object found; initialising...")
# htm <<- htmMake()
#}
htmPath = getwd()
## create the package:
# package.skeleton(name="htmTool",path=path, code_files=c("classes.R","gui.R","plots.R","functions.R","install.R"))
guiToolkit("tcltk")
source("plots.R")
source("functions.R")
source("gui.R")
## make package
## - you can simply delete all files in the man directory to get through "check"
## - check has options to ignore certain issues
# R CMD build
# R CMD check
# R CMD INSTALL
## only "export" functions that you want the user to see;
## also only for those you need to write documenation
## Roxygen