Horzcat
水平的串联阵列
描述
C= horzcat(
连接A1,,,,一个2,…,An
)A1
,,,,A2
,…,,一个
horizontally.
Horzcat
相当于使用方括号用于水平串联阵列。例如,[A,B]
or[A B]
等于Horzcat(A,B)
什么时候一个
andb
是兼容阵列。
例子
输入参数
Tips
一个lgorithms
For table inputs,Horzcat
在存在时通过匹配行名称或匹配表位置来连接。Horzcat
assigns values for the描述
andUserData
properties of the output using the first nonempty values of the corresponding properties of the input.
When concatenating an empty array to a nonempty array,Horzcat
省略输出中的空数组。例如,horzcat([1 2],[])
返回行矢量[1 2]
。
如果所有的输入参数s are empty and have compatible sizes, thenHorzcat
returns an empty array whose size is equal to the output size as when the inputs are nonempty. For example,horzcat(零(0,1),零(0,2))
返回一个0 x-3空数组。如果输入尺寸不兼容,则Horzcat
returns a 0-by-0 empty array.
扩展功能
Introduced before R2006a