T = innerjoin(left, right)
T = innerjoin(left, right, 'Keys', keys)
T = innerjoin(left, right, 'LeftVariables', leftVars, 'RightVariables', rightVars)
| Parameter | Description |
|---|---|
| left, right | Input tables. |
| keys | Key variable names. |
| leftVars, rightVars | Variables to keep from the left and right tables. |
| Parameter | Description |
|---|---|
| T | Table containing rows with matching keys in both inputs. |
innerjoin keeps only rows whose key values are present in both tables.
L = table([1; 2; 3], [10; 20; 30], 'VariableNames', {'Key', 'LeftValue'});
R = table([2; 3; 4], [200; 300; 400], 'VariableNames', {'Key', 'RightValue'});
J = innerjoin(L, R, 'Keys', 'Key')
| Version | Description |
|---|---|
| 2.0.0 | initial version |