Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ununderstood problem trying to apply the AURELHY method #2

Open
rababyy opened this issue Sep 14, 2017 · 1 comment
Open

Ununderstood problem trying to apply the AURELHY method #2

rababyy opened this issue Sep 14, 2017 · 1 comment

Comments

@rababyy
Copy link

rababyy commented Sep 14, 2017

Hello,

I am trying to use this interpolation technique to achieve the same result as Morocco, in my case it is the French Pyrénées. You will find my code below :
library('aurelhy')

#read ascii grid and convert it into a geotm object

dem_path <- 'D:/These_PLVG-IMFT-ENIT/Prog/SpatialisationPluies_BVGP/PERFECT_RASTER/intdem30.asc'
GP_dem <- read.geotm(file=dem_path, type = "ascii")

#Read ASCII grid into and convert it as a geomask object

mask_path <- 'D:/These_PLVG-IMFT-ENIT/Prog/SpatialisationPluies_BVGP/PERFECT_RASTER/mask30.asc'
GP_mask <- read.geomask(file=mask_path, type = "ascii")

#Read station data into a dataframe

rain_path <- 'D:/These_PLVG-IMFT-ENIT/Prog/SpatialisationPluies_BVGP/POSTES_BVGP_EV2012.csv'
rain_df <- read.csv(rain_path)

#Rain interpolation
maurelhy <- aurelhy(GP_dem, GP_mask)

And the error that I get is the following one :
Error in par["x2"] <- par["x1"] + nrow(x) * par["size"] :
replacement has length zero

I don't really understand this error message, could you please tell me what does it mean ?
You will find attached the files I used to apply the aurelhy method.

Thanks in advance for your time and help,
Rabab
GP_AUREHYINTERPOLATION.zip

@rodrigueg
Copy link

Hello @rababyy ,

I am having the same "replacement has length zero" error. Did you manage to find out how to fix it?

Thanks in advance.
RG

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants