# MWEL state graph

**URL:** <https://mworks.discourse.group/t/mwel-state-graph/268>\
**Category:** Support\
**Created:** [April 8, 2019, 1:23pm UTC](https://mworks.discourse.group/t/mwel-state-graph/268 "2019-04-08T13:23:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [April 8, 2019, 1:23pm UTC](https://mworks.discourse.group/t/mwel-state-graph/268/1 "2019-04-08T13:23:07Z")

</div>

Hi Chris,

I wrote some code a while ago to parse the XML experiment files and produce a state machine graph (example attached). This helps me a lot during debugging, especially for more complicated expts.

Is there an easy way to convert the MWEL files to XML so I can use this?  
Or alternatively, would you be interested in taking this code, bringing it up to date, and including it in MWorks?

Mark

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [April 8, 2019, 1:35pm UTC](https://mworks.discourse.group/t/mwel-state-graph/268/2 "2019-04-08T13:35:58Z")

</div>

Hi Mark,

> Is there an easy way to convert the MWEL files to XML so I can use this?

Yes, like this:

```
/Library/Application\ Support/MWorks/MWEL/mwel2xml exp.mwel > exp.xml

```

If you want the output to be a bit more readable (by a human), use the option `--omit-metadata`:

```
/Library/Application\ Support/MWorks/MWEL/mwel2xml --omit-metadata exp.mwel > exp.xml

```

Cheers,  
Chris

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 19, 2022, 8:54pm UTC](https://mworks.discourse.group/t/mwel-state-graph/268/3 "2022-07-19T20:54:33Z")

</div>


