Home > SuperSegger > Internal > col.m

col

PURPOSE ^

row : makes v into a col vector.

SYNOPSIS ^

function [ v ] = col( v )

DESCRIPTION ^

 row :  makes v into a col vector.
 INPUT : 
   v: array or row vector.
 OUTPUT : 
   v: vector converted to row vector.
 Copyright (C) 2016 Wiggins Lab 
 Written by Stella Stylianidou, Paul Wiggins.
 University of Washington, 2016
 This file is part of SuperSegger.
 
 SuperSegger is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation, either version 3 of the License, or
 (at your option) any later version.
 
 SuperSegger is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 GNU General Public License for more details.
 
 You should have received a copy of the GNU General Public License
 along with SuperSegger.  If not, see <http://www.gnu.org/licenses/>.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [ v ] = col( v )
0002 % row :  makes v into a col vector.
0003 % INPUT :
0004 %   v: array or row vector.
0005 % OUTPUT :
0006 %   v: vector converted to row vector.
0007 % Copyright (C) 2016 Wiggins Lab
0008 % Written by Stella Stylianidou, Paul Wiggins.
0009 % University of Washington, 2016
0010 % This file is part of SuperSegger.
0011 %
0012 % SuperSegger is free software: you can redistribute it and/or modify
0013 % it under the terms of the GNU General Public License as published by
0014 % the Free Software Foundation, either version 3 of the License, or
0015 % (at your option) any later version.
0016 %
0017 % SuperSegger is distributed in the hope that it will be useful,
0018 % but WITHOUT ANY WARRANTY; without even the implied warranty of
0019 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0020 % GNU General Public License for more details.
0021 %
0022 % You should have received a copy of the GNU General Public License
0023 % along with SuperSegger.  If not, see <http://www.gnu.org/licenses/>.
0024 
0025 ss = size(v);
0026 
0027 if ~any( ss==1 )
0028     v = v(:);
0029 elseif ss(1) == 1
0030     v = v';
0031 end
0032 
0033 end
0034 
0035

Generated on Thu 19-Jan-2017 13:55:21 by m2html © 2005