Can multiple applystops() of same loss type coexist at same time?

The code segment below uses multiple ApplyStop() of stopTypeLoss.

//max stop loss
ApplyStop(stopTypeLoss,
         stopModePercent,
         10, //cut loss at 10%
         True );
//breakeven stop
ApplyStop( stopTypeLoss , stopModePercent , 0, True , False , 0, 0, -1, 
                  ActivationFloor=10 );

Will the second ApplyStop() over-ride the first ApplyStop()? Can both co-exist, given that both are of the same type stopTypeLoss?

@thankyou18, did you try that code?

I think that this is the kind of thing that you can answer yourself with a bit of experimentation.

More in general, it is useful to remember that it is possible to combine different types of stops but in that case we should keep in mind their order precedence.

2 Likes

Hi beppe,

Thanks for replying. I have verified my own question. The answer is yes. I tried to post this several hours ago but the post was awaiting approval. The original post is still awaiting approval. Not sure why.

I don't know how did you arrive to your incorrect conclusion, but the answer is that multiple ApplyStops are of course supported but they have to use different TYPE.

If you use two or more ApplyStop with same type (stopTypeLoss) the LAST call to ApplyStop will overwrite anything that was set earlier for that particular stop type. That way you OVERWRITE stops defined in the Analysis Settings. Anything in the code OVERWRITES stops defined in Analysis settings.

4 Likes

@Tomasz, Thank you for correcting me. I have deleted the post with the wrong conclusion.

Deleting content like that is not welcome because it makes subsequent responses out of context and nonsense.

1 Like

@Tomasz, Ok. I have restored the post.

The reason I delete is because I'm afraid it will mislead other readers. Some people don't read the entire thread. Anyway, I have restored the post as I respect your wishes.

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.