Ideas to programatically change all variable names in M-files and SL model?

1 ビュー (過去 30 日間)
Esteban 2014 年 11 月 12 日
回答済み: Julia 2014 年 11 月 12 日
we have a very complex SL model (ranges from 13-18Mb) and it has initializing scripts written as M-files. Most of the model parameters are loaded from excel files. Because we're working very closely with Mathworks, we have come to the point where we need to share one of our models with them. The problem is that there is a lot of industry know how going on in this models and we don't want to directly make this public. In short, we need to show Mathworks the whole complexity of our models without showing any of our industry know-how. One idea was to change consequently all variable names across the excel files, M-files and SL model together with their values. To do this by hand represents a mammoth task and before we start trying to reinvent the wheel, I wanted to ask here if someone has been confronted with a similar challenge before. Cheers!


Julia 2014 年 11 月 12 日
I once had a similar problem with changing a lot of variable names.
I solved it using Notepad++: open Notepad and then open your Simulink model in Notepad. Now you can replace with search and replace the names. I think the same works for M-files, and Excel has the same functionality (search and replace) as far as I know.

その他の回答 (0 件)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by