How to save a Workspace cell variable in a folder out of matlab?

3 ビュー (過去 30 日間)
Leila
Leila 2020 年 9 月 30 日
コメント済み: Ameer Hamza 2020 年 10 月 1 日
I have an image cell in workspace and want to save them in a folder in my desktop. how could I di that?

採用された回答

Ameer Hamza
Ameer Hamza 2020 年 9 月 30 日
Use imwrite(): https://www.mathworks.com/help/matlab/ref/imwrite.html. You can specify complete path to desktop. For example
img = % image matrix
path_to_desktop = 'C:\...'; % write the path to desktop
name_image_file = 'image.jpg'; % name of image file
filepath = fullfile(path_to_desktop, name_image_file);
imwrite(img, filepath)
  2 件のコメント
Leila
Leila 2020 年 10 月 1 日
yes it works, Thank you
Ameer Hamza
Ameer Hamza 2020 年 10 月 1 日
I am glad to be of help!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeImages についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by