Matlab to other file dot transfer as comma??
9 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
at matlab for numbers 'dot' is used as a decimal symbol but when I try to paste this numbers to the other files (excel,text file) it turns automatically 'comma'. I did all other changes in windows but the problem results from matlab likely. How can I solve this comma dot confusion at matlab?
2 comentarios
Stephen23
el 5 de Ag. de 2016
Editada: Stephen23
el 5 de Ag. de 2016
@byzt3005: this likely has nothing to do with MATLAB, but depends on your Windows/Office/... settings. They will interpret a decimal values depending on your locale/language settings. It is possible to fiddle around and try to get everything to play nicely, but in my experience it always fails somewhere...
The most reliable solution is to install and use the US English version of Windows (and other programs), then this problem never arises. As most programming languages use US English this makes many things much simpler: e.g. the US keyboard layout is easier to write code with too.
Luis Corbala Robles
el 8 de Jun. de 2017
What I did:
1-Control Panel -> Region and Language
2-[Formats] Choose Format: "English (United Kingdom)"
3-Restart computer
Note(s):
-Does not necessarily need to be "English (United Kingdom)", what matters is that in [Additional Settings (within [Formats])] the Decimal Symbol is set to "." (i.e. dot).
Respuestas (2)
Gustav Karner
el 14 de En. de 2020
Go to Preferences and chose Variables.
Change "Decimal separator for exporting numeric data via clipboard:" to a point.
0 comentarios
Andreas Goser
el 5 de Ag. de 2016
I tried the following
a=1.2
in MATLAB and then select and copy the "1.2" from the MATLAB R2016a command window.
Then I pasted into a Notepad file - > "1.2"
Then I pasted into a MS Excel file - > "01. Feb"
I assume this happens as of Excel interprets the string based on my language and local settings as a date. Maybe this happens to you to?
0 comentarios
Ver también
Categorías
Más información sobre Entering Commands en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!