필터 지우기
필터 지우기

How to Save data generated during a function execution

조회 수: 14 (최근 30일)
Aakriti Srivastava
Aakriti Srivastava 2022년 8월 13일
댓글: Aakriti Srivastava 2022년 8월 15일
I am working on automation project, while running my script I call a function with some input argument which returns a result to me, but in the meanwhile the function also creates snp file of the schematic, I want to store that data but I cant ask it as output argument from the function. Is there any way to store data created within the function, Please let me know.

답변 (1개)

Image Analyst
Image Analyst 2022년 8월 13일
I don't know why you say that. You can save data created inside the function in a variety of ways and formats. Or, you can also return the variables to the calling function and save them there instead. Or you can actually do both if you want.
Perhaps if you shared a simplified snippet of what you want to do, we could guide you. And tell us
  1. what variable(s) you want to save
  2. where you want to save it (in the script or the function)
  3. what format do you want to save in (text file, spreadsheet, .mat file, image file, sound file, etc.)
  댓글 수: 3
Image Analyst
Image Analyst 2022년 8월 13일
Did you try functions such as writematrix of fprintf?
Aakriti Srivastava
Aakriti Srivastava 2022년 8월 15일
No I havent tried that but will do, thanks

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Text Files에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by