fopen user guide in MATLAB
来源:互联网 发布:五矿证券软件下载 编辑:程序博客网 时间:2024/06/07 22:03
refer to: http://cn.mathworks.com/help/symbolic/mupad_ref/fopen.html
And: http://cn.mathworks.com/help/matlab/ref/fopen.html
Syntax
fopen(filename | TempFile
, <Read | Write | Append
>, <Bin | Text | Raw
>, <Encoding = "encodingValue"
>)
Bin
, Raw
, Text
With Bin
, the data is stored in MuPAD internal binary format. WithText
, the data may be strings or MuPAD objects stored as text. Newlines are handled according to the conventions of the operating system at hand. WithRaw
, the data is interpreted as binary machine numbers. See the functionsreadbytes
andwritebytes
.
If the mode is Read
or Append
, the default is the format of the data in the existing file. If the mode isWrite
, the default isBin
.
Encoding
This option lets you specify the character encoding to use. The allowed encodings are:
"Big5"
"ISO-8859-1"
"windows-932"
"EUC-JP"
"ISO-8859-2"
"windows-936"
"GBK"
"ISO-8859-3"
"windows-949"
"KSC_5601"
"ISO-8859-4"
"windows-950"
"Macintosh"
"ISO-8859-9"
"windows-1250"
"Shift_JIS"
"ISO-8859-13"
"windows-1251"
"US-ASCII"
"ISO-8859-15"
"windows-1252"
"UTF-8"
"windows-1253"
"windows-1254"
"windows-1257"
'Big5'
'ISO-8859-1'
'windows-847'
'Big5-HKSCS'
'ISO-8859-2'
'windows-949'
'CP949'
'ISO-8859-3'
'windows-1250'
'EUC-KR'
'ISO-8859-4'
'windows-1251'
'EUC-JP'
'ISO-8859-5'
'windows-1252'
'EUC-TW'
'ISO-8859-6'
'windows-1253'
'GB18030'
'ISO-8859-7'
'windows-1254'
'GB2312'
'ISO-8859-8'
'windows-1255'
'GBK'
'ISO-8859-9'
'windows-1256'
'IBM866'
'ISO-8859-11'
'windows-1257'
'KOI8-R'
'ISO-8859-13'
'windows-1258'
'KOI8-U'
'ISO-8859-15'
'US-ASCII'
'Macintosh'
'UTF-8'
'Shift_JIS'
The default encoding is system dependent. If you specify the encoding incorrectly, characters might read incorrectly. Characters unrecognized by the encoding are replaced by the default substitution character for the specified encoding.
Encodings not listed here can be specified but might not produce correct results.
Return Values
a positive integer: the file descriptor. FAIL
is returned if the file cannot be opened.
Example
To specify the encoding to read and write data, use Encoding
. TheEncoding
option applies only to text files that are opened using a file name and not a file descriptor. Create a temporary file and write the string"abcäöü"
in the encoding "UTF-8"
:
fid := fopen(TempFile, Text, Write, Encoding="UTF-8"):file := fname(fid):fprint(Unquoted, fid, "abcäöü"):fclose(fid):
- fopen user guide in MATLAB
- user guide
- user guide
- PL/SQL Developer Version Control Plug-In User’s Guide
- MATLAB fopen函数分析
- matlab的fopen
- matlab的fopen
- 整理:matlab的fopen
- matlab的fopen
- MATLAB之fopen函数
- matlab的fopen
- GCC User Guide
- commons-fileupload user guide
- proxool user guide
- ubuntu user guide
- Auto Test User Guide
- Axis2 User's Guide
- EJBCA User Guide
- 私信基本功能数据库设计
- 用rpm包安装gcc
- php手册之Trait
- 浏览器 模仿QQ聊天 对话框
- JavaWeb_利用Session实现简易购物车
- fopen user guide in MATLAB
- Matlab注释语句
- 洛谷:JSOI2008 最大数
- ListView 中 TextView 添加跑马灯效果
- windows下启动mysql服务的命令行启动和手动启动方法
- 5ucms编辑器fckeditor的一些说明
- 三级缓存
- Matlab中断语句
- uGUI事件系统简述及使用方法总结