PureBytes Links
Trading Reference Links
|
<SPAN
class=193300614-13052003>Mark,
I
think the problem is that writeif looks only to the last bar of data. This is
why I used the work around I submitted to you yesterday. You said your were
feeding another program the data. If that program was excel or something similar
could you use an if type statement to return the appropriate string if the
result were 0 or 1?
Regards,
Jayson
<FONT face=Tahoma
size=2>-----Original Message-----From: markf2
[mailto:feierstein@xxxxxxxxx]Sent: Tuesday, May 13, 2003 9:20
AMTo: amibroker@xxxxxxxxxxxxxxxSubject: [amibroker] Re:
Exploration Help PleaseGraham- Your logic for what I
want to accomplish is good, but whichfunctions to use and how to use them is
the problem. For example, toadd a column with text you must use
AddTextColumn. But WriteIf giveserror messages when inside it.
So I tried this as simple test code:level=WriteIf(C >
25,"Hi","Lo");Filter=1;AddColumn(C, "C", 1.4
);AddTextColumn(level,"Close Level");Unfortunately this always
returns "Hi", even if C<=25. I think the issue is how to insert a
string into AddTextColumn that varies basedon a condition, but nothing I've
tried works. Any more ideas? Thanksfor your efforts,
BTW.Mark--- In amibroker@xxxxxxxxxxxxxxx, "Graham"
<gkavanagh@xxxx> wrote:> Do you mean something like>
EnterLong = flip(buy,sell);> ExitLong = flip(sell,buy);>
Entershort = flip(short,cover);> ExitShort =
flip(cover,short);>Addcolumn(writeif(EnterLong,"long",writeif(ExitLong,"out",writeif(EnterShort>
,"short",writeif(ExitShort,"out")))),"trade");> > Don't know if it
works, but could be something to start with, if itworkds> that
is> > Cheers,> Graham> <A
href="">http://groups.msn.com/ASXShareTrading>
<A
href="">http://groups.msn.com/FMSAustralia>
> -----Original Message-----> From: markf2
[mailto:feierstein@xxxx] > Sent: Tuesday, 13 May 2003 8:16 PM> To:
amibroker@xxxxxxxxxxxxxxx> Subject: [amibroker] Exploration Help
Please> > Hello Everyone,Is it possible to to add a column of text
to an> exploration that indicates whether a trading system is long,
short, or> out of the market? Specifically, I need to add a column that
specifies> "Long" or "Short" (depending on which is the case) beginning
with the> bar of entry, through and including the bar before the bar of
exit,> then "Out" beginning with the exit bar and continuing for all bars
the> system's not in the market, etc. I'd like to do this directly
with> whatever array(s)track this info, because inferring it through
the> relationship between the equity function and prices doesn't
always> work (for example, problems with lag if exiting with a delay).
Thanks.> Mark> > > > Send BUG REPORTS to
bugs@xxxx> Send SUGGESTIONS to suggest@xxxx>
-----------------------------------------> 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<A
href="">http://docs.yahoo.com/info/terms/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.
|