Persistent Example - Loading Data Only When Needed

Working with persistent variables.

現在この提出コンテンツをフォロー中です。

This example demonstrates how to use persistent variables when loading data in a function. Doing things this way guarantees that the "data" value in "persistentFunction" is only loaded or changed when necessary.
This is very useful in cases such as:
- "data" is large and loaded from a network location. Network locations are not as fast as locally saved data.
- The data is large and doesn't change much from call to call of "persistentFunction"

引用

Jason Nicholson (2026). Persistent Example - Loading Data Only When Needed (https://jp.mathworks.com/matlabcentral/fileexchange/67076-persistent-example-loading-data-only-when-needed), MATLAB Central File Exchange. に取得済み.

カテゴリ

Help Center および MATLAB AnswersDeployable Archive Creation についてさらに検索

一般的な情報

MATLAB リリースの互換性

  • すべてのリリースと互換性あり

プラットフォームの互換性

  • Windows
  • macOS
  • Linux
バージョン 公開済み リリース ノート Action
1.1.0.0

Better documentation.
Embedding of persistentFunction html still didn't work. Maybe it will work this time.
I had to hack the HTML because Mathworks doesn't render embeded iframe tags correctly. The persistentFunction HTML was put inline in the persistentExample

1.0.0.0