# Update a vector with "update\_param!"

**URL:** <https://forum.mimiframework.org/t/update-a-vector-with-update-param/116>\
**Category:** Uncategorized\
**Created:** [April 18, 2020, 12:17am UTC](https://forum.mimiframework.org/t/update-a-vector-with-update-param/116 "2020-04-18T00:17:52Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![lrennels](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.mimiframework.org/lrennels/32/6_2.png) [@lrennels](https://forum.mimiframework.org/u/lrennels)\
**Post date:** [April 22, 2020, 9:18pm UTC](https://forum.mimiframework.org/t/update-a-vector-with-update-param/116/2 "2020-04-22T21:18:46Z")

</div>

@KGregory I believe your problem here is that you are trying to index into `:agcbm`, which is not permitted within this function. If you want to update the vector array, you will need to replace the entire array, i.e. `update_param!(m, :agcbm, new_array]` where the `new_array` is a 16 element vector as well. Does that make sense for your use case? Of course, your new array might just be a replica of the original one used in `set_param!` with the first value modified. I assume you can access that original vector from the original `set_param!` function, or pulling the values out of the already run model?

---

_[View the full topic](https://forum.mimiframework.org/t/update-a-vector-with-update-param/116)._
