We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Question: Batch Macro outputs only zeros, correct output with single inputs

robertbyg
5 - Atom

I'm trying to calculate value weighted returns for a long short momentum portfolio. The workflow gives me the correct output for single inputs, but outputs only zeros when I try to run it as a batch macro for repeated inputs. What should I do different to get the correct outputs instead of just zeros? Any help would be highly appreciated!

 

Screenshot 2023-03-26 154027.png

 

Screenshot 2023-03-26 154142.png

2 REPLIES 2
BS_THE_ANALYST
15 - Aurora
15 - Aurora

@robertbyg I think I can see the issue here:
These 3 you want to pick 202301

BS_THE_ANALYST_0-1679839005451.png

Then you have this one which is a different value 201302

BS_THE_ANALYST_1-1679839020015.png

 

However, once you run your macro (batch it), this is happening:

BS_THE_ANALYST_2-1679839090337.png

BS_THE_ANALYST_3-1679839108904.png

The same month is being selected, resultantly, you end with 0s because in the end (after your calculations, you will see this):

BS_THE_ANALYST_4-1679839167866.png

Hence the 0s. So you need to reconsider your approach here.

The way I ran a simulation of your batch macro was doing the following:

BS_THE_ANALYST_5-1679839262924.png


Open the interface designer, get to test view, enter a test value, open debug:

BS_THE_ANALYST_6-1679839298035.png

Therefore, you can debug issues with your macro! 

Hopefully that helps.

Thanks,
BS

 

All the best,
BS

LinkedIN

Bulien
robertbyg
5 - Atom

Thank you!

Labels
Top Solution Authors