PureBytes Links
Trading Reference Links
|
<SPAN
class=711043222-12122003>Hi Gary, I saw your EI post and want to investigate,
but unless I'm misunderstanding something, that's not the issue I'm trying to
get at. It seems like you'd use EI to put you in stocks that move
without big changes in volatility, which I'd think would allow more tailored
stops, among other things.
<SPAN
class=711043222-12122003>
<SPAN
class=711043222-12122003>What I'm wondering about is positions that don't move
at all, or stop moving after you've held them a while. For instance, say you get
a great bump up immediately after entry, then it just sits there flat. Doesn't
hit a stop since it's not falling, didn't go high enough to hit a target if you
have one, just sits.
<SPAN
class=711043222-12122003>
<SPAN
class=711043222-12122003>My code was an effort at kicking positions like that
out the door at some point, so their capital can be used for other things. It
didn't test out profitably in the context I checked it though. Not sure what
that means.
<SPAN
class=711043222-12122003>
<SPAN
class=711043222-12122003>Dave
<SPAN
class=711043222-12122003>
<BLOCKQUOTE dir=ltr
>
I like your code, and your idea. In terms of an alternative, Al
posted Tharpe's Efficiency Index which addresses chop. Here's his code
and explaination. Regards,
Gary
Effiency Index (EI) = (C - ref(C,-x)/ATR(x)
An efficient stock is a stock whose price movements are high
relative to its volatility changes (i.e., the price change is high but the
volatility change is minor). So, if a stock increases by 3 points while its
volatility only increases a little, that's good because it gives you greater
profitability at a given volatility.
I think the way you would use it would be as a boolean Buy (or
Short) qualifier. In other words, something like this:
Buy = <your normal buy rules> AND EI > y; //where y
is an optimizable variable.Dave Merrill
<dmerrill@xxxxxxx> wrote:
<BLOCKQUOTE class=replbq
>Obviously,
losses are a problem. But so are positions that hang in thereforever
taking up available cash but going nowhere, without hitting
profittargets or stops.How would you code that, assuming you're
dealing with a system that tries todump losers but let winners run as
long as they're advancing.I tried starting from a modest stoploss,
with the stop percentage advancingevery day until it becomes negative,
enforcing the requirement to make aprofit or get off the bus. I'm not
certain, but I think it's working, justnot very profitable in the
context I tried it:.Here's the
code:----------------bars_since_buy = NZ(BarsSince(buy),
BarCount);bars_since_short = NZ(BarsSince(short),
BarCount);bars_since_entry = IIf(bars_since_buy < bars_since_short,
bars_since_buy,bars_since_short);stoploss_rise = Optimize("stoploss
rise", .5, .1, 1, .1);stoploss = 13 - (stoploss_rise *
bars_since_entry);ApplyStop(stopTypeLoss, stopModePercent, stoploss,
false, true, 0);----------------Anyone see any problems with the
implementation? Any other ideas foravoiding sitting in stagnant
positions?DaveSend BUG REPORTS to
bugs@xxxxxxxxxxxxxSend SUGGESTIONS to
suggest@xxxxxxxxxxxxx-----------------------------------------Post
AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page:
<A
href="">http://groups.yahoo.com/group/amiquote/messages/)--------------------------------------------Check
group FAQ at: <A
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the <A
href="">Yahoo! Terms of Service.
Do you Yahoo!?<A
href="">New
Yahoo! Photos - easier uploading and sharing Send
BUG REPORTS to bugs@xxxxxxxxxxxxxSend SUGGESTIONS to
suggest@xxxxxxxxxxxxx-----------------------------------------Post
AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page:
<A
href="">http://groups.yahoo.com/group/amiquote/messages/)--------------------------------------------Check
group FAQ at: <A
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the <A
href="">Yahoo! Terms of Service.
Yahoo! Groups Sponsor
ADVERTISEMENT
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
|