Re: 答复: About QuantLib::TimeSeries again

Posted by Rob on
URL: http://quantlib.414.s1.nabble.com/Re-About-QuantLib-TimeSeries-again-tp14030p14431.html

Hi Luigi,

Thanks for the feedback, I found a solution. I created a new version of timeseries.hpp, replacing Date with DateTime, where DateTime is a Boost ptime typedef. Thus, I'm using Boost ptime as the key, which works very nicely since it comes with lots of functionality. 

Thanks,

Rob.


On Sun, Jul 7, 2013 at 7:57 AM, Luigi Ballabio <[hidden email]> wrote:
Hello Rob,
    currently there's no class in QuantLib providing a timestamp.
You'll have to create a structure yourself containing a date and a
time, and use that as a key (I think you'll have to implement operator
< to make it work).

Luigi


On Thu, Jul 4, 2013 at 2:42 PM, Rob <[hidden email]> wrote:
> Hi Guys,
>
> The standard QuantLib TimeSeries class uses a date object as a key. What if
> I want to also include a timestamp in addition to a date? Is this possible
> in Quantlib?
>
> Thanks, Rob.
>
>
>
> --
> View this message in context: http://quantlib.10058.n7.nabble.com/Re-About-QuantLib-TimeSeries-again-tp14030p14410.html
> Sent from the quantlib-users mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users



--
<https://implementingquantlib.blogspot.com>
<https://twitter.com/lballabio>


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users