# Extracting Patient Coefficients From SSM Modes

**URL:** <https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485>\
**Category:** MIS - Scripting Forum\
**Tags:** 3-matic\
**Created:** [August 5, 2021, 8:32pm UTC](https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485 "2021-08-05T20:32:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![IAF2022](https://avatars.discourse-cdn.com/v4/letter/i/278dde/32.png) [@IAF2022](https://community.materialise.com/u/IAF2022)\
**Post date:** [August 5, 2021, 8:32pm UTC](https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485/1 "2021-08-05T20:32:16Z")

</div>

Is it possible to extract the mode coefficients that correspond to the patients used to create the SSM? That is, what coefficient combination will yield an SSM instance equivalent to one of the patients used to create the SSM?

Thank you in advance for your assistance,

Ian

---

<div class="post-metadata">

**Author:** ![Marnic](https://avatars.discourse-cdn.com/v4/letter/m/b9bd4f/32.png) [@Marnic](https://community.materialise.com/u/Marnic)\
**Post date:** [August 6, 2021, 2:09pm UTC](https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485/2 "2021-08-06T14:09:54Z")

</div>

Hey Ian,

One of the attributes of an SSM is an overview of all the coefficients of all input parameters. You can use the following code to have a closer look (code originating from 3-matic 15, might differ in V16):

SSM\_patient = SSM\_patient\_data  
coeff = SSM\_patient[index].coefficients

Let me know in case it doesn’t work.

Kind regards,  
Marnic

---

<div class="post-metadata">

**Author:** ![IAF2022](https://avatars.discourse-cdn.com/v4/letter/i/278dde/32.png) [@IAF2022](https://community.materialise.com/u/IAF2022)\
**Post date:** [August 17, 2021, 6:58pm UTC](https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485/3 "2021-08-17T18:58:15Z")

</div>

Hi Marnic,

I appreciate your assistance with my problem. The code you gave seems like a generalized version of what you’re referring to. I don’t quite understand how to apply it to an actual SSM. Would you mind providing an example of code you’d use to find the coefficients of an SSM’s patients? For example, what is contained in the SSM\_patient\_data variable you provided above?

Thank you for your time,

Ian

---

<div class="post-metadata">

**Author:** ![IAF2022](https://avatars.discourse-cdn.com/v4/letter/i/278dde/32.png) [@IAF2022](https://community.materialise.com/u/IAF2022)\
**Post date:** [September 1, 2021, 4:02pm UTC](https://community.materialise.com/t/extracting-patient-coefficients-from-ssm-modes/485/4 "2021-09-01T16:02:41Z")

</div>

Resolution:

The line of code needed to extract an SSM’s patient’s coefficients is this;  
“coefficient\_list = ssm.patient\_data[index].coefficients”  
where the variable “index” determines which patient you want to find the coefficients of.

If you’re looking for a specific coefficient of an SSM’s patient the code would be this instead;  
“coefficient = ssm.patient\_data[index].coefficients[index2]”

Hope you find this useful,

Ian
