How do I determine my MATLAB default character encoding scheme?

Using unicode2native with a single argument, it defaults to "the MATLAB default character encoding scheme". How do I find out what my default is?

답변 (4개)

Grzegorz Knor
Grzegorz Knor 2011년 9월 8일
Use java class:
import java.nio.charset.Charset
encoding = Charset.defaultCharset()

댓글 수: 2

On my box, this returns "windows-1252", which sounds right. Are we sure that MATLAB and Java are always in sync on this?
"MATLAB, unless you specify a particular encoding will use the computer's (user's) default encoding."
<http://blogs.mathworks.com/loren/2006/09/20/working-with-low-level-file-io-and-encodings/>

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

Grzegorz Knor
Grzegorz Knor 2011년 9월 8일
get_param(0, 'CharacterEncoding')
Jan
Jan 2011년 9월 8일
Matlab 2009a, WindowsXP:
get(0, 'Language')
% >> 'en_us.windows-1252'

카테고리

도움말 센터File Exchange에서 Data Type Identification에 대해 자세히 알아보기

제품

질문:

2011년 9월 8일

Community Treasure Hunt

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

Start Hunting!

Translated by