Create, activate, and use calculated attributes from the mParticle user interface. You can then view calculated attributes along with other user attributes in the UI or via the Profile API.
Click on the data criteria section to define the data used to run the calculation.
Save your changes.
To adjust a date range for your calculation, click on Date Range criteria:
Select Within the last from dropdown for calculations that must be made over a specific rolling time period. Enter a number and specify a time unit of Days or Weeks, and then Save your changes.
A calculated attribute must first be activated in order for mParticle to start calculating its values across your users.
To activate a Calculated Attribute:
When activated, mParticle will start to compute and initialize the initial value for the calculated attribute.
Depending on the date range, volume of data in your workspace, and complexity of definition, calculations will have varying SLAs before it first becomes available across your customer profiles. Whilst calculating, the UI will display its calculation progress.
You use the default behavior for forwarding calculated attributes forwarding, or you can use the special Calculated Attributes feed.
mParticle automatically enriches incoming batches with active calculated attributes for that user. Just like regular user attributes, you can restrict which outputs receive them, using data filters.
The Calculated Attributes feed allows you to send calculated attributes downstream whenever they change, without an event from the user; this feed is especially useful for keeping calculated attributes with asynchronous calculations synchronized throughout your stack, and for sending calculated attributes downstream alongside kit integrations.
If your output partner supports the Calculated Attributes Feed, the input appears once you have activated a calculated attribute. When a new connection is made to this input, CA values for users who have not been seen since their asynchronous CAs were calculated will be sent. This feed sends an update when calculated attributes change (both synchronous & asynchronous), it does not send user attributes.
To control which downstream system receives these updates, connect specific platforms to receive the calculated attribute updates. You can also filter out calculated attributes you do not wish to forward using the platform filters page.
The calculated attributes feed is available with the following partners:
Calculated attributes can be viewed alongside other user attributes in the Live Stream, the User Activity view, and are accessible via the Profile API.
Use calculated attributes in the Audience builder by selecting User > Calculated Attributes.
Calculated attributes appear as ‘string’ types at first and then automatically switch to the correct type as they are computed across many users. You can build audience criteria with a calculated attribute even if it is calculating. After the attribute values are completed for each user, their audience membership is updated.
Seeding allows you to pass in historic values for calculated attributes that mParticle will build upon as new data arrives, without passing in all the raw events. This allows you to seamlessly transition from your own calculations to mParticle’s.
To use seeds with a calculated attribute:
Define a calculated attribute in the mParticle platform prior to sending any seed.
The CA can be in either draft or active state, however, we recommend the calculated attribute be activated after seeds for all users have been sent to mParticle. Once a calculated attribute is activated, mParticle starts calculating it, and thus some users may show inaccurate values until seeds have been received.
Send seeds via the Calculated Attributes Seeding API.
Once mParticle has received seeds, mParticle combines them with calculated attribute results based on live data received after the cutoff date.
After seeds have been sent to mParticle, any of the following changes make the previously received seeds invalid and are deleted from mParticle.
If you need to update the seeds after already sending them to mParticle, simply send the updated seeds to mParticle again. mParticle overwrites previously received seeds.
If you are loading historical data using the historical endpoint of the HTTP API, after the load you must recreate new calculated attributes or update the definition of an existing CA to trigger a recalculation.
Was this page helpful?