indiTraders - Forum for the Active Indian Trader  

Go Back   indiTraders - Forum for the Active Indian Trader > Tools > Software > ArthaChitra

Reply
 
Bookmark and Share LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-04-2015, 01:58 AM
devdas's Avatar
devdas devdas is offline
edevaay.com
 
Join Date: Mar 2009
Location: Tactical Hell....
Posts: 5,387
Thanks: 15,762
Thanked 18,335 Times in 5,079 Posts
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
Default ArthaChitra : BiColorLine PlotStyle

Hi Joy perhaps you missed this morning post

ArthaChitra feedback

about

Code:
if(Values[0][0] > Values[0][1] ) Plots[0].Pen = penUp;
                 else if(Values[0][0] < Values[0][1] ) Plots[0].Pen = penDn;
I tried many trials with Pens and Brushes but that didnt worked , finally i set with last undesirable option to see if this is the only way. My query about above is still open, and for time being new development evolved other queries too.

Here i coded BiColorLine PlotStyle for that purpose its working as per coding in it. Now there are two main concern about this,

1) If this is the only way for time being to achieve this then it will need separate similar version for most plot style if we want a dual color effect in plots. This is certainly not desirable.

2) If this is the only way then how can i write a Xaml for PlotStyle settings and where to place that ?


Attached Files
File Type: zip BiColorLinePlotStyle.zip (870 Bytes, 5 views)
__________________
Harvest The Moon !!
Nest The Market !!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following 4 Users Say Thank You to devdas For This Useful Post:
  #2 (permalink)  
Old 10-04-2015, 10:59 AM
joy joy is online now
indiTraders VIP
 
Join Date: Mar 2009
Posts: 1,201
Thanks: 1,108
Thanked 4,103 Times in 1,090 Posts
joy has a reputation beyond repute
joy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond reputejoy has a reputation beyond repute
Default

devdas,
my apologies, I missed it.

Please try the below code, to change the color

Code:
if (CurrentBar > 1 && Values[0][0] > Values[0][1])
{
       base.BarBrush[0] = Brushes.Blue;
       base.PlotPens[0][0] = new Pen(Brushes.Blue, 2);
}
Please note the corresponding ChartStyle must also implement the GetBarOverrideBrush(..) method to get the overriden Brush (please see the @CandleStick chartstyle).

Similarly the corresponding PlotStyle must implement the GetPlotOverridePen(..) to get the overriden Pen (please refer to the @CSharp PlotStyle).
__________________
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following 3 Users Say Thank You to joy For This Useful Post:
  #3 (permalink)  
Old 10-04-2015, 10:41 PM
devdas's Avatar
devdas devdas is offline
edevaay.com
 
Join Date: Mar 2009
Location: Tactical Hell....
Posts: 5,387
Thanks: 15,762
Thanked 18,335 Times in 5,079 Posts
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
Default

Originally Posted by joy View Post
devdas,
my apologies, I missed it.

Please try the below code, to change the color

Code:
if (CurrentBar > 1 && Values[0][0] > Values[0][1])
{
       base.BarBrush[0] = Brushes.Blue;
       base.PlotPens[0][0] = new Pen(Brushes.Blue, 2);
}
Please note the corresponding ChartStyle must also implement the GetBarOverrideBrush(..) method to get the overriden Brush (please see the @CandleStick chartstyle).

Similarly the corresponding PlotStyle must implement the GetPlotOverridePen(..) to get the overriden Pen (please refer to the @CSharp PlotStyle).

Now working.
Thanx for your support.
__________________
Harvest The Moon !!
Nest The Market !!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following 5 Users Say Thank You to devdas For This Useful Post:
  #4 (permalink)  
Old 14-04-2015, 02:38 PM
devdas's Avatar
devdas devdas is offline
edevaay.com
 
Join Date: Mar 2009
Location: Tactical Hell....
Posts: 5,387
Thanks: 15,762
Thanked 18,335 Times in 5,079 Posts
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
devdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond reputedevdas has a reputation beyond repute
Default

Corrected and

Update : Added support for up-down color changes.

Restart ArthaChitra after Import.
Attached Files
File Type: zip BiColorLinePlotStyle.zip (885 Bytes, 4 views)
__________________
Harvest The Moon !!
Nest The Market !!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following 2 Users Say Thank You to devdas For This Useful Post:
  #5 (permalink)  
Old 07-10-2015, 05:19 PM
Rocky01's Avatar
Rocky01 Rocky01 is offline
Regular
 
Join Date: Jun 2009
Posts: 35
Thanks: 0
Thanked 25 Times in 18 Posts
Rocky01 is on a distinguished road
Default

CAN YOU KINDLY CONVERT THIS CODE INTO AMIBROKER FORMULA.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following User Says Thank You to Rocky01 For This Useful Post:
Reply

indiTraders - Forum for the Active Indian Trader > Tools > Software > ArthaChitra


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT +5.5. The time now is 03:30 PM.


vBulletin Copyright by vBulletin

Content Relevant URLs by vBSEO 3.3.2