---
schema_version: "1"
id: 1df194bdc554f35549dbeedd5b1b3bea3f8def541d76b56fc7d91098f1508801
title: Considerations for Preparing Data
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/analytics/264-0-0/bi_edd_prep_considerations.md
canonical_url: https://help.salesforce.com/s/articleView?id=analytics.bi_edd_prep_considerations.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 6b86ada9f9a515beb5fbca7002de0b39fe54faca9bcd76a9be658f184e5bdce6
description: Consider these guidelines when preparing your data for Einstein Discovery.
products:
  - CRM Analytics
  - Cross Cloud
release: "264"
---
# Considerations for Preparing Data

Consider these guidelines when preparing your data for Einstein Discovery.

## Optimize Your Data for Analysis

To get the best results from Einstein Discovery's comprehensive analytical capabilities, your dataset must contain the highest-quality data possible. To optimize data for machine learning, modeling, and AI:

- Your data must be _accurate_.
- Your data must be _complete_.
- Your data must sufficiently represent your real-world business operations in terms of quantity (volume) and variation (diversity).
- Your data must be relevant to the business outcome you want to analyze or predict.

In reality, data is imperfect, especially when you first begin working with it. You run across missing and incorrect values, spelling variations and other inconsistencies, outliers that are correct or not, duplicate and redundant information, and other issues that can obscure the operational reality of what your data represents.

With data prep, you can remedy these faults in your data so that Einstein Discovery consumes the best version of the truth. The result? More relevant insights and higher-quality models.

## Assess Your Source Data and Correct Issues at the Source

Assess the condition of your source data. As you collect the data into variables, profile the values. Look for data problems, such as extremes, outliers, missing values, incorrect values, skew, and high cardinality. Common data preparation issues are identified during the data-loading process.

We recommend that you address data quality issues as early as possible. You can repair them in CRM Analytics, in the source system, or in your data preparation process. If you are seeing errors from source applications, a best practice is to resolve the issue at the source system instead of during data preparation.

## Consolidate Data from Multiple Sources

Using CRM Analytics tools like Data Prep, you can pull data stored in a dimensional data warehouse or in a transactional database format. If so, use record identifiers or primary keys to join fields from multiple tables to create a single, unified, flattened view. Your view contains an outcome variable, along with input predictor variables collected at a level of analytical granularity on which you can make actionable decisions.

For many outcome variables, data is captured at various business process steps in multiple data sources. For example, a sales process can have data in a CRM, an email marketing program, and Excel spreadsheet, and an accounting system. If that is the case, identify the fields in those systems that can link the different data sources together.

## Ensure that Observations are Independent

Einstein Discovery algorithms assume that each observation is independent and is not related to other observations. If relationships exist between observations, create a variable within the row of data to capture that behavior. For example, if the same Opportunity has multiple competitors, don’t prepare multiple rows of data with the same Opportunity ID. Instead, create more fields on one Opportunity ID and indicate whether each of the top-10 competitors were present in the deal.

## Calculate Durations for Date Values

Dates can be rolled up to duration values and used as input for analysis. If a business process has multiple key dates, use the Data Manager to create multiple variables in which to store numeric durations (for example, Days between Lead to Last Contact and Days between Demo to Trial). Common date variable rollups include the earliest date and the most recent date. Time durations can also be represented in either absolute or relative form.

## Maximize Interpretability for Insights

When preparing your data, consider the downstream effects of your decisions. Keep in mind the importance of making charts and explanations easier for users to review and interpret. For example, for categories, keep the number of unique values low (too many categories create cluttered bar charts) and use consistent spelling.

## Apply CRM Analytics Considerations To Your Data

Review the following articles under [Considerations Before Integrating Data into Datasets](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_considerations.htm&release=264.0.0&type=5 "This section covers expected behavior and limitations to consider before integrating data into datasets."):

- [Handle Numeric Values](https://help.salesforce.com/s/articleView?id=analytics.bi_numeric_values.htm&release=264.0.0&type=5 "CRM Analytics internally stores numeric values in datasets as long values. For example, CRM Analytics stores the number 3,200.99 with a scale of 2 as 320099. The user interface converts the stored value back to decimal notation to display the number as 3200.99.")
- [Handle Date Values](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_date_generation.htm&release=264.0.0&type=5 "When CRM Analytics loads dates into a dataset, it breaks up each date into multiple columns, such as day, week, month, quarter, and year, based on the calendar year. For example, if you extract dates from a CreateDate column, CRM Analytics generates columns such as CreateDate_Day and CreateDate_Week. If your fiscal year differs from the calendar year, you can enable CRM Analytics to generate fiscal date columns as well.") and [Handle Custom Time Zone Values](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_timezone_handling.htm&release=264.0.0&type=5 "Time zone support lets you view time-specific data on dashboards in a time zone that you specify for your org. By default, CRM Analytics datasets aren’t time-zone aware, so CRM Analytics treats all date-time values as being in GMT. The data you see on your dashboards is in GMT, regardless of your local time zone. When you enable time zone support, CRM Analytics converts date-time values in your datasets to the time zone selected for CRM Analytics. You can then create time zone enabled dashboards to display these converted date-time values. Users see dashboard data in the single custom time zone you set, not their personal timezone specified in Salesforce. Recipe formulas and filters with date-time fields operate in GMT.")
- [Handle Text Values](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_text_column_handling.htm&release=264.0.0&type=5 "Confirm that text values in a column are uniform in formatting, spelling, and language. Inconsistencies can occur within data sources and after merging data from multiple data sources.")
- [Handle Missing Values](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_missing_value_handling.htm&release=264.0.0&type=5 "Gaps in your data can throw off analysis. Missing values are best fixed in the source application by, for example, making it a required field. However, if you can’t do that, you can use CRM Analytics to fill in missing data.")

#### See Also

- [Collect, Cleanse, and Optimize Your Data](https://help.salesforce.com/s/articleView?id=analytics.bi_edd_prep_cleanse.htm&release=264.0.0&type=5 "All data prep efforts are oriented toward providing the best data you can for the business outcome you want to examine or predict. CRM Analytics provides the tools you need to consolidate, clean, and prepare your data for analysis. This topic describes approaches to consider when preparing data for your solution.")