How to remove decimal points in the Workspace
6 次查看(过去 30 天)
显示 更早的评论
I want to remove decimal points in the workspace, I have a bunch of variables in the editor and want to be able to quickly reference the output in the work space but when i do they are in scientific notation. Ive tried changing the veiw but nothing works. Ill show an example below but some other things that I have tried is rounding, format longG and others, but nothing removes the decimal all together.
I have an excel sheet with alot of different variables, in numerous columns, I want to add all the values together to have just one total. Afterward Ill graph all of the different totals.
Heres how I am doing it now:
a1 =
339.750000000000
339.750000000000
339.750000000000
339.750000000000
339.750000000000
a2 = sum(a1);
output for a1 = 1.698750+03
a3 = round(a2,2);
after rounding, a3 = 1.698750+03
what I am looking for = 1698.75
When I open the variable in workspace I want it to look like the final number, 1698.75, instead of 1.698750+03. Any advice is appreciated!
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!