about candlestick in EasyLanguage

pencil2

Newbie
Messages
6
Likes
0
Dear all

I have two questions about candlestick setting in EL

1. How to analysis Open/Close prise in the last week during daily chart?
I would like to set the strategy to compare the open/close prise between nearest two weeks, buy I am not sure that reserved words "openw(1) & closew(1)" are correct.

2. How to find the maximun candle body in a week(Monday~Friday)? Furthermore, how to find the nearest bullish candlesticks(it doesn't have to continue)?

I'm such a idiot please help me, thank you!!
 
What type of chart are you applying this to ? You seem to indicate that you are using a daily chart for this ??

When you say compare the open and close price of the week are you wanting to know for instance if the price on Friday is higher or lower than the starting price on Monday of the same week or over N weeks ?

With this you are wanting to find the tallest candle body that occurred within the past week which would be nearly the same as above. You are asking what was the biggest open to close difference this week on any given day??

Answer these questions and add in anything else that you might like to see and I will get you all fixed up.
 
Dear StratOpt

Thank you very very much!!

1. Yes! I'm using a daily chart.
2. In fact, I want to compare two candlestick bodies between two weeks. -->(Monday Open Price & Friday Close Price) in this week and (the Monday Open Price & Friday Close Price) in the last week.
3. Sorry for my poor English; first, I would like to know the tallest candle body(the biggest open to close difference) in a week, for example, here are differences in a week (5, 6, 4, 3, 1), and "6" is what I want to find out. Second, I want to find the nearest three bullish candlesticks, for example, (+5, -1, +2, -5, +3), and "+5" "+2""+3" are answers.(they are not continual three candlesticks)

Thank you so much!!
 
Ok, let me build you something up. Don't be concerned with your English, I live in the US and can barely do it.

Dear StratOpt

Thank you very very much!!

1. Yes! I'm using a daily chart.
2. In fact, I want to compare two candlestick bodies between two weeks. -->(Monday Open Price & Friday Close Price) in this week and (the Monday Open Price & Friday Close Price) in the last week.
3. Sorry for my poor English; first, I would like to know the tallest candle body(the biggest open to close difference) in a week, for example, here are differences in a week (5, 6, 4, 3, 1), and "6" is what I want to find out. Second, I want to find the nearest three bullish candlesticks, for example, (+5, -1, +2, -5, +3), and "+5" "+2""+3" are answers.(they are not continual three candlesticks)

Thank you so much!!
 
// Yes! I'm using a daily chart.

inputs:
NumUps ( 3 ) ;

variables:
WeekOneDiff ( 0 ) ,
WeekTwoDiff ( 0 ) ,
TallBody ( 0 ) ,
BodyHeight ( 0 ) ,
Step ( 0 ) ,
DOW ( 0 ) ;

DOW = DayOfWeek( date ) ;

// In fact, I want to compare two candlestick bodies between two weeks. -->
// (Monday Open Price & Friday Close Price) in this week and
// (the Monday Open Price & Friday Close Price) in the last week.

if DOW = Friday then
begin
TallBody = 0 ;
WeekOneDiff = CloseW( 0 ) - OpenW( 0 ) ;
WeekTwoDiff = CloseW( 1 ) - OpenW( 1 ) ;

// first, I would like to know the tallest candle body(the biggest open to close difference) in a week, for example,
// here are differences in a week (5, 6, 4, 3, 1), and "6" is what I want to find out.
// This assumes a full week of values. To do holidays requires more

for Step = 0 to 4
begin
BodyHeight = AbsValue( OpenD( Step ) - CloseD( Step ) ) ;
if BodyHeight > TallBody then TallBody = BodyHeight ;
end ;
end ;

// Not sure about how far back you are wanting to check for three UPS
// If only during a week then you might not have any ups at all
// To Come later

// Also not sure what you are wanting to do with things, but you can do about anything you like once you have the values in variables
 
Dear StratOpt
It is a hopeless understatement to say that I'm deeply grateful.
Thank you very very much. I would try it right now.
 
Let me know the things that are wrong with it. I didn't test it any, and it is not a complete work as I don't know about your last request, but it is a start.
 
Dear StrarOpt

I would like to share my strategy to you for many thanks, and I'm not good at using EL now.
For Sell Signal, I set it as two steps, step one is about weekly candlestick and step two is about daily candlestick.
(I) weekly : {[weekonediff>weektwodiff] AND [weekone is bearish and weektwo is bullish]} AND [(weekonediff/Monday) > 7%] OR [weekonerange/Monday > 14%]

(II) daily : [TallBody is bearish] AND [TallBody is bigger than the summary of 3 nearly bullish body] AND [TallBody/Open > 7%]

However, TallBody should be "nearly five days", for example, if today is Tuesday, then the nearly five days is Monday, Friday(last week), Thursday(last week), Wednesday(last week), Tuesday(last week).
Finally, about how far back I want to trace "the nearly 3 bullish days" is not limited during this week, I just want to find the nearly 3 bullish candlesticks and summrize there bodies.
I hope my explain is clear enough to recover my poor English. :)
Thank you, anyway.
 
BTW, I also have two questions.
1. For opening a new document, should I create this as a "function" , "indicator" or "strategy"? I create as function and the EL reveals warning when I press bottom "F3".

2. What reserved word indicate "current price", is it "price" or "market"?
 
Hi all

To find out the nearly 3 bullish candlesticks, but I'm not sure if it is correct :

Value1 = CountIF(Close > Open, 3);
 
Top