Skip to content

Commit

Permalink
Typo corrected
Browse files Browse the repository at this point in the history
  • Loading branch information
MGousseff committed Sep 20, 2024
1 parent 8bcb002 commit 4df056b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/importLCZraster.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ importLCZraster<-function(dirPath, bBox, fileName="EU_LCZ_map.tif", LCZband=1, L
if (sum(class(bBox)%in%c("sfc_POLYGON","sfc" ))==0) {
bBox<-st_as_sfc(bBox)
}
bBox<-st_transform(bBox, st_crs(filePath,proj=TRUE))
bBox<-st_transform(bBox, st_crs(sfFile,proj=TRUE))


cropTry<-try(sfFile %>% crop(bBox))
Expand All @@ -85,7 +85,7 @@ importLCZraster<-function(dirPath, bBox, fileName="EU_LCZ_map.tif", LCZband=1, L
names(sfFile)[names(sfFile)==LCZband]<-LCZcolumn
names(sfFile)[names(sfFile)==confidenceBand]<-confidenceColumn
print(str(sfFile))
sfFile<-sfFile%>% mutate(!!LCZcolumn:=fct_recode(factor(subset(sfFile,select=LCZcolumn,drop=T),levels=typeLevels),
sfFile<-sfFile%>% mutate(!!LCZcolumn:=fct_recode(factor(subset(sfFile,select=all_of(LCZcolumn),drop=T),levels=typeLevels),
!!!typeLevels)) %>%
drop_na(LCZcolumn)

Expand Down

0 comments on commit 4df056b

Please sign in to comment.