![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1485477/image.png)
I accidentally closed my tab with matlab online can I recover my work
15 views (last 30 days)
Show older comments
hello, due to borrowing a laptop I have been foced to use matlab online with my google chrome browser. I accidentally closed the tab and all my data is lost. For some reason I still have all the variables in the work space without the script. Can I recover my live script?
0 Comments
Answers (1)
Siraj
on 18 Sep 2023
Edited: Siraj
on 18 Sep 2023
Hi!
It appears that you accidentally closed your MATLAB Online tab and lost all your data. However, when you reopened the tab, you noticed that all the variables in the workspace were still there. This suggests that you must have executed your file at least once before, which implies that the file was likely saved somewhere in the MATLAB Drive.
In order to locate the file in the MATLAB Drive, you can utilize the toolstrip located on the left side of the MATLAB Online interface. By using this toolstrip, you will be able to search for the file and retrieve it. I've attached image of the toolstrip.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1485477/image.png)
If you are unable to locate the file in the MATLAB Drive or if it does not exist, then if the variables in your workspace contain the crucial data you need, you can export them to a file format like MAT or CSV. This can be achieved by using the "save" function to save the variables in a MAT file, or by utilizing the "writematrix" function to save them in a CSV file. By saving the data in this way, you can access it later when needed. Refer to the following link to learn more about the "save" and "writematrix" functions.
Hope this helps.
0 Comments
See Also
Categories
Find more on Environment and Settings in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!