Union

This transform finds the union of two datasets and returns all the elements of both datasets without duplicates.

tags: [“Data Preparation”]

Parameters

This table provides a brief description about each parameter in Forward Fill transform.

Name:

By default, the transform name is populated. You can also add a custom name for the transform.

First Input Dataset:

The file name of the first dataset. You can select this dataset from the drop-down list. (Required: True, Multiple: False)

Second Input Dataset:

The file name of the second dataset. You can select the other dataset from the drop-down list. to perform Union operation. (Required: True, Multiple: False)

Union Dataset:

The file name of the output dataset having all elements of both datasets. (Required: True, Multiple: False)

The sample input for this transform looks as shown in the screenshot:

../../../_images/union_input.png

The output after running the Union transform on the dataset appears as below:

../../../_images/union_output.png

How to use it in Notebook

The following is the code snippet you must use in the Jupyter Notebook editor to run the Union transform:

template=TemplateV2.get_template_by('Union')

recipe_Union= project.addRecipe([car_data, employee_data, temperature_data, only_numeric], name='Union')

transform=Transform()
transform.templateId = template.id
transform.name='Union'
transform.variables = {
'input_dataset':'car',
'input_dataset':'car',
'output_dataset':'union'}
recipe_Union.add_transform(transform)
recipe_Union.run()

Requirements

pandas