Print Page | Close Window

Chart-type

Printed From: TMS Software
Category: VCL Components
Forum Name: VCL Chart
Forum Discription:
URL: http://www.tmssoftware.com/site/forum/forum_posts.asp?TID=10029
Printed Date: 05 Dec 2019 at 5:51pm


Topic: Chart-type
Posted By: Janssens Dirk
Subject: Chart-type
Date Posted: 31 May 2018 at 9:05pm
Hello,

Is there an easy/logical way to represent stock-value or price-changes in time.
I would like to see something like this :

https://jajaja.home.xs4all.nl/tmp/ChartExample.png - Chart Example

I have looked at all the examples, and tried some things with ctLine, no luck...

Can somebody give me a hint ?

kind regards,

Dirk Janssens.






Replies:
Posted By: Bruno Fierens
Date Posted: 01 Jun 2018 at 12:35pm
Did you try the Digital Line type?


Posted By: Janssens Dirk
Date Posted: 01 Jun 2018 at 12:59pm
Yes, but it;s not clear how to use it ..
I tried AddSingleXYPoint, but it seems that the X-value is ignored.
AddSingleXYPoint(10,2) -> i see a point at [1,2]
AddSingleXYPoint(110,1) -> i see a point at [2,1] etc ..



Posted By: Bruno Fierens
Date Posted: 01 Jun 2018 at 8:10pm
This is not an XY chart type.
For Digital line type, AddSinglePoint() needs to be used.


Posted By: Janssens Dirk
Date Posted: 04 Jun 2018 at 8:53am
Thank you Bruno. But I still have trouble understanding this. Is it alwas so, that only the Y-value can be set, and that every point add's to the next x-value ?
Suppose, I want to see the price of an article since 2000. And the price has changed say 10 times since 1-1-2000. Do I need to set the value for *every* day from 1-1-2000 to today ?
Maybe I overlook something ?

kind regards,

Dirk.


Posted By: Pieter Scheldeman
Date Posted: 04 Jun 2018 at 10:00am
Hi, 

There is a ctXYDigitalLine chart type available in the TMS VCL Chart, but alternatively you should investigate TMS FNC Chart which has a better date-time integration/configuration, and each chart type is automatically an XY chart type. ( http://www.tmssoftware.com/site/tmsfncchart.asp - http://www.tmssoftware.com/site/tmsfncchart.asp )


Posted By: Janssens Dirk
Date Posted: 05 Jun 2018 at 9:39am
Thank you Pieter,,
I am making progress, but find it not so easy, and not intuitive. I don't have the FNC Chart, so if it is possible to do it with the VCL Chart. i go for that.
Still, I am having doubts if it is even possible to generate a chart like this :

https://jajaja.home.xs4all.nl/tmp/ChartExample.png - example

Maybe a few lines of code just to get me started would help a lot...
I did not find demo's. Are there any ??

kind regards,

Dirk.


Posted By: Pieter Scheldeman
Date Posted: 05 Jun 2018 at 2:33pm
Hi, 

The chart in the screenshot should be possible. There are demo's included that are installed under ...\My Documents\tmssoftware\

In this folder, a sub-folder with the name of the chart is available which contains a set of demos such as the Overview demo, that demonstrate the various line types, including digital line.


Posted By: Janssens Dirk
Date Posted: 05 Jun 2018 at 5:22pm
I don't see any samples/demos. Is it possible to download them seperatly ?


Posted By: Bruno Fierens
Date Posted: 05 Jun 2018 at 9:35pm
The samples get installed automatically along the components itself when you install the registered version. Please look under your Documents folder under tmssoftware\TMS Advanced Charts and there in sub folder named "Demo overview"


Posted By: Janssens Dirk
Date Posted: 06 Jun 2018 at 10:06am
Hi Bruno,

Thanks, I found it. I was looking in the wrong "Documents" folder.. I'll take a look at the demo's

Dirk.,


Posted By: Janssens Dirk
Date Posted: 06 Jun 2018 at 10:36am
I guess, to make it like the example, I have to add 2 points for a change of value :

price change on 1/5/2017 would be :

AddSingleXYPoint(ConvertDateTimeTox("01-01-2015", 10) ; //start of chart

AddSingleXYPoint(ConvertDateTimeTox("01-05-2017", 10) ; //draw straight line to date of change

AddSingleXYPoint(ConvertDateTimeTox("01-01-2015", 12) ; //new price

AddSingleXYPoint(ConvertDateTimeTox("TODAY", 12) ; //end of chart

That is OK for me, but is it possible to get rid of the bullits ? When there are a lot of changes in a short periode of time, this gets messie..

regards,

Dirk.


Posted By: Pieter Scheldeman
Date Posted: 06 Jun 2018 at 11:34am
Hi, 

For a real date/time sample please take a look at the following tip/faq:
https://www.tmssoftware.com/site/advchart.asp?s=faq&show=293 - https://www.tmssoftware.com/site/advchart.asp?s=faq&show=293




Print Page | Close Window