Combining datasets
DataFrames and Series can be combined using built-in functions in Danfo.js. Methods such as danfo.merge and danfo.concat exist that, depending on the configurations, can help you combine datasets in different forms using familiar database-like joins.
In this section, we'll briefly talk about these join types, starting with the merge function.
DataFrame merge
The merge operation is similar to the database Join operation in that it performs join operations on columns or indexes found in the object. The signature of the merge operation is as follows:
danfo.merge({left, right, on, how}) Let's understand what each parameter entails:
left: The left-hand side DataFrame/Series you want to merge to.right: The right-hand side DataFrame/Series you want to merge to.on: The name(s) of the column(s) to join. These column(s) must be found in both the left and right DataFrames.how: Thehowparameter specifies how the merge should...