[R-sig-Geo] space time error message

Milan Kilibarda milan.kili11 at gmail.com
Fri Aug 8 15:07:21 CEST 2014


Dear Abdoulaye,

Regarding to your Error message, I guess you should check if the time
format in your observation set was appropriate. In spacetime package
POSIXct is preferable. See  ? as.POSIXct, for easy converting from
string to POSIX* format. If you still have problem, than you should
send at least  str(dprec84) and str(stations1), or even better make
small subset in mail of your data, then people from the list could try
to reproduce the problem; try to find solution; and it can help
someone with a similar problem.
Best,
Milan

> prec <- meteo2STFDF(dprec84,stations1, crs= CRS('+proj=longlat +datum=WGS84'))
Joining by: staid, date

Joining by: staid
Error in  ST(sp, time, endTime) : time is not a time based class

On Fri, Aug 8, 2014 at 1:55 PM, Abdoulaye Sarr <abdoulayesar at gmail.com> wrote:
> I am still hoping to have a quick explanation on what is causing the error
> or a suggestion on another way to do it?
>
> Cheers,
> eus
>
>
> On Sun, Aug 3, 2014 at 2:20 PM, Abdoulaye Sarr <abdoulayesar at gmail.com>
> wrote:
>
>> I think the problem could be related to dates in precip, in fact here I am
>> using dekadal precip( 10 days average therefor for each month you have 01,
>> 11 and 21 as you can see in the date in sample dataframes dprec84.rda and
>> the stations1.rda.
>>
>> After creating these dataframes I am trying to use use meteo to create a
>> STFDF (I guess other packaged could do it?) using the command below:
>>
>> > prec <- meteo2STFDF(dprec84,stations1, crs= CRS('+proj=longlat
>> +datum=WGS84'))
>> Joining by: staid, date
>>
>> Joining by: staid
>> Error in  ST(sp, time, endTime) : time is not a time based class
>>
>> If doable with other package also will be fine for me.
>>
>> asarr
>>
>>
>> On Sun, Aug 3, 2014 at 9:40 AM, Edzer Pebesma <
>> edzer.pebesma at uni-muenster.de> wrote:
>>
>>> Please provide a small, reproducible example.
>>>
>>> Wbr,
>>>
>>> On 07/26/2014 08:29 PM, Abdoulaye SARR wrote:
>>> >
>>> > Hello list,
>>> >
>>> > I am creating a space time full data frame but having this error
>>> message:
>>> >
>>> > Joining by: staid
>>> > Error in ST(sp, time, endTime) : time is not a time based class
>>> >
>>> > the data frame 10 days average precip used looks like this:
>>> >
>>> >      staid       time prec
>>> > 1 38007200 1984-01-01  0.0
>>> > 2 38008400 1984-01-01  0.8
>>> > 3 38014000 1984-01-01  0.0
>>> > 4 38008100 1984-01-01  0.0
>>> > 5 38008700 1984-01-01  0.0
>>> > 6 38009200 1984-01-01  0.0
>>> >
>>> >
>>> > The next date 1984-01-11 etc..
>>> >
>>> > could someone help solve this urgent issue.
>>> >
>>> > Best regards,
>>> >
>>> > eus
>>> >
>>> >
>>> >       [[alternative HTML version deleted]]
>>> >
>>> > _______________________________________________
>>> > R-sig-Geo mailing list
>>> > R-sig-Geo at r-project.org
>>> > https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>>> >
>>>
>>> --
>>> Edzer Pebesma
>>> Institute for Geoinformatics (ifgi), University of Münster
>>> Heisenbergstraße 2, 48149 Münster, Germany. Phone: +49 251
>>> 83 33081 http://ifgi.uni-muenster.de GPG key ID 0xAC227795
>>>
>>>
>>> _______________________________________________
>>> R-sig-Geo mailing list
>>> R-sig-Geo at r-project.org
>>> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>>>
>>>
>>
>
>         [[alternative HTML version deleted]]
>
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>



-- 
Dr. Milan Kilibarda
Assistant professor
University of Belgrade,
Faculty of Civil Engineering,
Department of Geodesy and Geoinformatics,
Address: Bulevar kralja Aleksandra 73  11000 Belgrade, Serbia,
Mail:  kili at grf.bg.ac.rs
Web: http://www.grf.bg.ac.rs/fakultet/pro/e?nid=168 ;  http://dailymeteo.org/
Pub: http://scholar.google.com/citations?user=Zl2MZ3AAAAAJ&hl=en
tel:+381 11 3218630



More information about the R-sig-Geo mailing list