- ago
Is it possible to create a custom indicator using the building blocks that is the average ROC of two external symbols? (For example, an indicator that is the average 5 day ROC for SPY and IWM)
0
88
Solved
6 Answers

Reply

Bookmark

Sort
- ago
#1
It's currently not possible to "nest" Transformer Indicators, which is what would be required to do this, so no.

It's easy to do in a code-based strategy, another option would be to open a Concierge Support engagement and we could develop a custom indicator library that you could use in Building Block Strategies, with parameters for the external symbols and ROC period.
0
Best Answer
- ago
#2
Thanks for your response, Glitch. It looks like I should make it a priority to learn how to write code-based strategies.
1
- ago
#3
QUOTE:
make it a priority to learn how to write code-based strategies.

I would read the first one-third of your C# textbook first, then start coding strategies. That will get you going with experience.

To do indicators will require more reading beyond that point so you learn about "classes" and how a static class differs from a class passed by reference (i.e. a non-static class). Typically indicators are static classes (but they don't have to be).

(OOP = Object oriented programming)
WL8 defines many datatypes. That's a big plus for an OOPs programmer because he can craft his strategies with high-level WL datatypes and methods minimizing the number of lines written. But it's overwhelming for everyone else because there are all these WL datatypes to learn listed in the WL QuickRef. Do not become overwhelmed. Just learn what you need as you go, and don't hesitate to learn a new datatype when you need it. You'll do fine. And welcome to OOPs programming.
0
- ago
#4
Just to add to Dion's reply: yet another option to create such indicator would be to use the built-in wizard for C# Indicator. Still, it requires some (very basic) coding skills.
1
- ago
#5
There's also an option to not create an indicator at all, but to create a C# "child" class (or "companion" class) inside your C# coded strategy. This is the easiest option, but you won't be able to do drag-and-drop with it like a regular indicator. You'll also need to embed this child class into each C# coded strategy that calls it since you won't be placing it into a Visual Studio external class (DLL) library.

Honestly, all my C# classes (including indicators) start out as child classes this way until they are debugged. Then I move them into DLL libraries and forget about them. These external libraries keep my main strategies high-level and short (150 to 300 lines). And that's the way professional programmers do it. Happy coding to you.
1
- ago
#6
Thanks everyone for your helpful input.
0

Reply

Bookmark

Sort