AssociationThread[{key1,key2,…}{val1,val2,…}]
gives the association key1val1,key2val2,….
AssociationThread[{key1,key2,…},{val1,val2,…}]
also gives the association key1val1,key2val2,….
AssociationThread
AssociationThread[{key1,key2,…}{val1,val2,…}]
gives the association key1val1,key2val2,….
AssociationThread[{key1,key2,…},{val1,val2,…}]
also gives the association key1val1,key2val2,….
Details
- If any of the keyi are repeated, later instances replace earlier ones.
- AssociationThread[keys:>values] yields an association in which every element uses a delayed rule.
Examples
open all close allBasic Examples (2)
Scope (1)
Properties & Relations (2)
Repeated keys replace earlier ones:
AssociationThread[{1, 2, 1} -> {"eins", "two", "one"}]AssociationThread[list1list2] and AssociationThread[list1,list2] are completely equivalent:
AssociationThread[{1, 2, 3} -> {Yesterday, Today, Tomorrow}] === AssociationThread[{1, 2, 3}, {Yesterday, Today, Tomorrow}]This is not true if using instead of :
AssociationThread[{1, 2, 3} :> {Yesterday, Today, Tomorrow}] === AssociationThread[{1, 2, 3}, {Yesterday, Today, Tomorrow}]See Also
Association AssociationMap Thread Transpose SparseArray
Function Repository: AssociationThrough
Related Guides
History
Text
Wolfram Research (2014), AssociationThread, Wolfram Language function, https://reference.wolfram.com/language/ref/AssociationThread.html.
CMS
Wolfram Language. 2014. "AssociationThread." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/AssociationThread.html.
APA
Wolfram Language. (2014). AssociationThread. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/AssociationThread.html
BibTeX
@misc{reference.wolfram_2026_associationthread, author="Wolfram Research", title="{AssociationThread}", year="2014", howpublished="\url{https://reference.wolfram.com/language/ref/AssociationThread.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_associationthread, organization={Wolfram Research}, title={AssociationThread}, year={2014}, url={https://reference.wolfram.com/language/ref/AssociationThread.html}, note=[Accessed: 13-June-2026]}