-
Notifications
You must be signed in to change notification settings - Fork 0
/
.Rhistory
135 lines (135 loc) · 6.31 KB
/
.Rhistory
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
library(readr)
alpha3 <- read_csv("alpha3.csv")
View(alpha3)
library(readr)
alpha1 <- read_csv("alpha1.csv")
View(alpha1)
names(apha3)[1] <- "SRC No."
names(alpha3)[1] <- "SRC No."
View(alpha3)
require(dplyr)
beta1 <- left_join(alpha3, alpha1, by = "SRC No.")
View(beta1)
View(beta1)
library(readr)
alpha4 <- read_csv("alpha4.csv")
View(alpha4)
library(readr)
alpha2 <- read_csv("alpha2.csv")
View(alpha2)
names(alpha2)[2] <- "Job Card No."
beta2 <- left_join(alpha2, alpha2, by = "Job Card No.")
remove(beta2)
beta2 <- left_join(alpha2, alpha4, by = "Job Card No.")
View(beta2)
View(beta1)
names(beta1)[13] <- "Job Card No."
gamma1 <- left_join(beta1, beta2, by = "Job Card No.")
write.csv(gamma1, "Final_Table_for_shapefile.csv", fileEncoding = "UTF-8")
write.csv(gamma1, "Final_Table_for_shapefile_2.csv", fileEncoding = "UTF-8", na = "")
require(rgdal)
require(sf)
Maharashtra <- st_read("Maharashtra_State.shp")
View(Maharashtra)
require(leaflet)
leaflet(Maharashtra)
require(mapview)
mapview(Maharashtra)
library(flexdashboard)
full_simp2 <- readRDS("C:/Users/shami/Desktop/For_R/full_simp2.rds")
View(full_simp2)
View(full_simp2)
remove(full_simp2)
devtools::install_github("kent37/summarywidget")
require(htmltools)
install.package(htmltools)
install.packages(htmltools)
library(flexdashboard)
library(leaflet)
library(crosstalk)
library(mapview)
library(tidyverse)
library(lubridate)
load("testing.RData")
Stein_Table_dataframe <- as.data.frame(Stein_Table)
colnames(Stein_Table_dataframe)[colnames(Stein_Table_dataframe)=="Year of Award (Start)"] <- "Year"
colnames(Stein_Table_dataframe)[colnames(Stein_Table_dataframe)=="Category of Project"] <- "Category"
Stein_Table_dataframe$Year <- as.numeric(Stein_Table_dataframe$Year)
Stein_Table_dataframe$Access_2 <- paste0("<a href='",Stein_Table_dataframe$`Access (Link)`,"'>",Stein_Table_dataframe$`Access (Link)`,"</a>")
Stein_Table_dataframe[Stein_Table_dataframe$Access_2 == "<a href='N/A'>N/A</a>", "Access_2"] <- "N/A"
Stein_Table_sd <- SharedData$new(Stein_Table_dataframe, group = "Stein1")
Stein_Table_datatable <- Stein_Table_dataframe[,c(2,4,5,6,7,8,9,16,11,13)]
colnames(Stein_Table_datatable)[colnames(Stein_Table_datatable)=="Access_2"] <- "Access"
Stein_Table_datatable2 <- Stein_Table_datatable
Stein_Table_datatable2[2,c(8:11)] <- "--do--"
library(flexdashboard)
library(leaflet)
library(crosstalk)
library(mapview)
library(tidyverse)
library(lubridate)
library(leaflet)
pal <- colorFactor(c("#006699","#B31B1B", "#6EB43F"), domain = c("Category C: Support for Stein Sites", "Category A: Support for Senior Scholarly Research", "Category B: Support for Student Research"))
leaflet(height = "100%" ,width = "100%" ,data = Stein_Table_sd, options = leafletOptions(preferCanvas = TRUE)) %>%
addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions()) %>%
addPolygons(Maharashtra)
class(Maharashtra)
require(sp)
Maharashtra_sp <- sf::as_Spatial(Maharashtra$geometry)
library(flexdashboard)
library(leaflet)
library(crosstalk)
library(mapview)
library(tidyverse)
library(lubridate)
library(leaflet)
pal <- colorFactor(c("#006699","#B31B1B", "#6EB43F"), domain = c("Category C: Support for Stein Sites", "Category A: Support for Senior Scholarly Research", "Category B: Support for Student Research"))
leaflet(height = "100%" ,width = "100%" ,data = Stein_Table_sd, options = leafletOptions(preferCanvas = TRUE)) %>%
addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions()) %>%
addPolygons(Maharashtra_sp)
library(leaflet)
leaflet(height = "100%" ,width = "100%" ,data = Maharashtra_sp, options = leafletOptions(preferCanvas = TRUE)) %>%
addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions()) %>%
addPolygons(Maharashtra_sp)
library(leaflet)
leaflet(height = "100%" ,width = "100%", options = leafletOptions(preferCanvas = TRUE)) %>%
addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions()) %>%
addPolygons(Maharashtra_sp)
library(leaflet)
Maharashtra_sp %>% addPolygons()
library(leaflet)
map1 %>% addPolygons(Maharashtra_sp)
library(leaflet)
leaflet(Maharashtra_sp)
library(leaflet)
leaflet(Maharashtra_sp)%>%addProviderTiles()%>%addPolygons()
library(leaflet)
leaflet(Maharashtra_sp)%>%addProviderTiles(providers$OpenStreetMap)%>%addPolygons()
library(flexdashboard)
library(leaflet)
library(crosstalk)
library(mapview)
library(tidyverse)
library(lubridate)
library(leaflet)
leaflet(Maharashtra_sp)%>%addProviderTiles(providers$OpenStreetMap)%>%addPolygons()
library(DT)
Nagpur_District <- st_read("Nagpur_district.shp")
getwd()
Nagpur_District <- st_read("Nagpur_district.shp")
Nagpur_District_sp <- sf::as_Spatial(Nagpur_District$geometry)
library(leaflet)
leaflet()%>%addProviderTiles(providers$OpenStreetMap)%>%addPolygons(Maharashtra_sp)%>%addPolygons(Nagpur_District_sp)
library(leaflet)
leaflet(data = Maharashtra_sp)%>%addProviderTiles(providers$OpenStreetMap)%>%addPolygons(Maharashtra_sp)%>%addPolygons(data = Nagpur_District_sp)
library(leaflet)
leaflet(data = Maharashtra_sp)%>%addProviderTiles(providers$OpenStreetMap)%>%addPolygons(data = Maharashtra_sp)%>%addPolygons(data = Nagpur_District_sp)
library(leaflet)
leaflet(options = leafletOptions(preferCanvas = TRUE))%>%addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions(updateWhenZooming = FALSE, updateWhenIdle = TRUE), group = "Carto Simple Outline") %>% addProviderTiles(providers$OpenTopoMap, options = providerTileOptions(updateWhenZooming = FALSE, updateWhenIdle = TRUE), group = "Openstreet Topo Map")%>%addPolygons(data = Maharashtra_sp)%>%addPolygons(data = Nagpur_District_sp)
Nagpur_District <- st_read("Nagpur_District_Villages.shp")
Nagpur_District <- st_read("Nagpur_district.shp")
Nagpur_District_sp <- sf::as_Spatial(Nagpur_District$geometry)
Nagpur_village_shapefiles <- st_read("Nagpur_district_villages.shp")
Nagpur_District_villages<- sf::as_Spatial(Nagpur_village_shapefiles$geometry)
library(leaflet)
leaflet(options = leafletOptions(preferCanvas = TRUE))%>%addProviderTiles(providers$CartoDB.Positron, options = providerTileOptions(updateWhenZooming = FALSE, updateWhenIdle = TRUE), group = "Carto Simple Outline") %>% addProviderTiles(providers$OpenTopoMap, options = providerTileOptions(updateWhenZooming = FALSE, updateWhenIdle = TRUE), group = "Openstreet Topo Map")%>%addPolygons(data = Maharashtra_sp)%>%addPolygons(data = Nagpur_District_sp)%>%addPolygons(data = Nagpur_District_villages)