# Vector of upper triangle

**URL:** <https://discourse.julialang.org/t/vector-of-upper-triangle/7764>\
**Category:** General Usage\
**Tags:** question\
**Created:** [December 14, 2017, 3:13pm UTC](https://discourse.julialang.org/t/vector-of-upper-triangle/7764 "2017-12-14T15:13:54Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![GunnarFarneback](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gunnarfarneback/32/1827_2.png) [@GunnarFarneback](https://discourse.julialang.org/u/GunnarFarneback)\
**Post date:** [December 14, 2017, 3:57pm UTC](https://discourse.julialang.org/t/vector-of-upper-triangle/7764/2 "2017-12-14T15:57:46Z")

</div>

`M[triu(trues(M))]`

See also [Half Vectorization](https://discourse.julialang.org/t/half-vectorization/7399)

---

_[View the full topic](https://discourse.julialang.org/t/vector-of-upper-triangle/7764)._
