Alteryx Designer Desktop Discussions

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

Passing Values between Tools (Analytics App)

JamesMalyk
7 - Meteor

Hi everyone,

 

I've hit a snag in an analytics app I'm building.

 

  1. Currently the app brings in a full account set (eg. 80,000 records)
  2. I have the user appending in a quantity of samples they'd like to see; and I'm passing the data through into another field (eg. 10 samples).
  3. A formula tool is updated to calculate how many samples will pass into my sample tool (80,000 / 10) = Random 1 in 8000 Chance for each record.
  4. I'm trying to pass the calculated 8000 values into my sample tool.

 

To do this, I'm assuming I'd pass the tool somehow out of my workflow, then back into the connecting sample tool.

 

I'm having a problem though; I don't know how to store a values to be passed from tool to tool. I'm assuming I'm doing something wrong here.

 

I don't want the user to have to enter the N value to be passed into the sample tool, as the 80,000 input quantity hugely varies depending on the sampled file they're looking at (eg. some files are 2,000 records, and some are 500,000 records); and the user doesn't know.. I don't want them to have to keep guessing at how many total records are passed in the file to make this decision, which is why I'm calculating the N value for them based off how many accounts they want to see.

 

Thank you,

 

James

4 REPLIES 4
MarqueeCrew
20 - Arcturus
20 - Arcturus
Could you add a random field rand() and sort the data by the random number? Now you can select your 10 records with the first N records?

Cheers,

Mark
Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
JamesMalyk
7 - Meteor

Yes! This works perfectly.. trying to overcomplicate things on my part; easy and perfect solution, still rather new here and haven't used that tool yet :)

 

Thank you!

MarqueeCrew
20 - Arcturus
20 - Arcturus
Please also see random sample tool.

https://help.alteryx.com/current/Macro-RandomRecords.htm

Cheers,

Mark
Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
JamesMalyk
7 - Meteor

Thank you Mark! I found this within the tools mastery area as well; it's very helpful, and appreciated.

Labels