产品
产品概览
Mathematica
Mathematica 学生版
Mathematica Home Edition
Wolfram
CDF Player
(免费下载)
可计算文档格式(CDF)
web
Mathematica
grid
Mathematica
Wolfram
Workbench
Mathematica
附加程序包
Wolfram|Alpha 产品
解决方案
解决方案概览
工程
航空航天与国防
化学工程
控制系统
电气工程
图像处理
工业工程
材料科学
机械工程
运筹学
光学
石油工程
生物技术与医药
生物信息学
医学影像
金融、统计、商业分析
精算科学
数据分析与挖掘
计量经济学
经济学
金融工程与数学
金融风险管理
统计
软件工程、内容传递
创作与出版
界面开发
软件工程
网页开发
科学
天文学
生物科学
化学
环境科学
地球科学
社会与行为科学
设计、艺术以及娱乐
游戏设计、特殊效果及衍生艺术
教育
STEM 教育倡议
高等教育
高职高专院校
中小学教育
学生
科技
可计算文档格式(CDF)
高性能并行计算(HPC)
参见:技术指南
购买
网上商店
其它购买方式
批量许可及站点许可证
联络销售部
软件
服务
升级
培训
书籍
技术支持
技术支持概览
知识库
学习中心
社区与论坛
培训
确认授权
Wolfram 用户门户
公司概况
关于 Wolfram Research
新闻与活动
Wolfram 博客
合作伙伴
工作机会
Mathematica
的历史
Stephen Wolfram 主页
联系我们
公司网站
全部站点
Wolfram|Alpha
演示项目
MathWorld
Integrator
Wolfram Functions Site
Mathematica Journal
Wolfram Media
Wolfram
Tones
Wolfram Science
Stephen Wolfram
DOCUMENTATION CENTER SEARCH
New to
Mathematica
?
Find your learning path
»
Mathematica
>
数据处理
>
导入和导出
>
Integer16
>
MATHEMATICA IMPORT/EXPORT 格式
Binary
Bit
Byte
Character8
Character16
Integer8
Integer32
Integer64
Integer128
UnsignedInteger8
UnsignedInteger16
UnsignedInteger24
UnsignedInteger32
UnsignedInteger64
UnsignedInteger128
Real32
Real64
Real128
Complex64
Complex128
Complex256
String
参见 »
|
Binary Data
Importing & Exporting
Listing of All Formats
更多关于 »
Integer16
Uniform sequence of signed 16-bit integers.
Binary data format.
Import
can read any file as a sequence of signed 16-bit integers.
Export
writes a list of integers in the range
to a binary file.
IMPORT 与 EXPORT
Import
imports an arbitrary file as a sequence of signed 16-bit integers, returning a packed array of integers in the range
.
Export
exports a list of integers in the range
to a binary sequence of 16-bit integers.
Import
or
Import
imports the specified element from
file
.
Import
imports multiple elements.
See the reference pages for full general information on
Import
and
Export
.
ImportString
and
ExportString
support the Integer16 format.
参数
General
Import
elements:
"Elements"
elements and options available in this file
"Rules"
full rules for each element and option
"Options"
rules for options, properties, and settings
Data representation element:
"Data"
list of integers in the range
By default,
Import
and
Export
use the
element.
Import
["
file
", {"Integer16",
n
}]
gives the
n
16-bit integer.
Trailing bytes are ignored if the size of the imported file is not a multiple of the data size.
选项
General option:
ByteOrdering
-1
what byte ordering to use
Import
option:
"HeaderBytes"
0
how many bytes to skip at the beginning of the file
参见
Binary
Bit
Byte
Character8
Character16
Integer8
Integer32
Integer64
Integer128
UnsignedInteger8
UnsignedInteger16
UnsignedInteger24
UnsignedInteger32
UnsignedInteger64
UnsignedInteger128
Real32
Real64
Real128
Complex64
Complex128
Complex256
String
更多关于
Binary Data
Importing & Exporting
Listing of All Formats
范例
关闭所有单元
例
(1)
Convert a list of integers to a string representing binary 8-bit signed integers:
Convert the binary data back to a list of integers:
Show the byte values of the exported data:
Import as 16-bit Unicode characters:
Interpret as raw 16-bit Unicode text:
Convert a list of integers to a string representing binary 8-bit signed integers:
In[1]:=
Out[1]=
Convert the binary data back to a list of integers:
In[2]:=
Out[2]=
Show the byte values of the exported data:
In[3]:=
Out[3]=
Import as 16-bit Unicode characters:
In[4]:=
Out[4]=
Interpret as raw 16-bit Unicode text:
In[5]:=
Out[5]=