jointable

Join pairs of tables using arbitrary keys
1,1K téléchargements
Mise à jour 24 sept. 2009

Afficher la licence

usage: jointable(tab1,tab2,keys1,keys2,fillval)

JOINTABLE works much like an SQL join, where each row of the join corresponds to rows of the tables with matching keys. Positions corresponding to non-matching keys are filled with the specified value.

Examples:

jointable([1;2;3],[4;5],{'a','b','c'},{'a','b'}) % join on string keys
jointable({'a';'b';'c'},{'d';'e'},[1,2,3],[1,2]) % join on numeric keys
jointable([1;2;3],[4;5],ones(1,3),ones(1,2)) % join on non-unique keys

The treatment of non-unique keys differs from that of an SQL full outer join.

NOTE: Requires LEXCMP (see below).

See the help for more details.

Citation pour cette source

Ben Petschel (2024). jointable (https://www.mathworks.com/matlabcentral/fileexchange/25311-jointable), MATLAB Central File Exchange. Récupéré le .

Compatibilité avec les versions de MATLAB
Créé avec R2009a
Compatible avec toutes les versions
Plateformes compatibles
Windows macOS Linux
Catégories
En savoir plus sur Tables dans Help Center et MATLAB Answers
Remerciements

Inspiré par : lexcmp

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Publié le Notes de version
1.1.0.0

n/a