Delimiter separated string to array conversion | function: Array = str2array(String, Delimiter)

Version 1.0.0.0 (928 Bytes) by Sugato
This function creates an array A from a delimiter-separated string S.
38 Downloads
Updated 12 Aug 2017

View License

Function Description:
This function creates an array A from a delimiter-separated string S.

AUTHOR: Sugato Ray | Created on: 25-APR-2017 | ray.sugato[at]gmail.com

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
PLEASE ACKNOWLEDGE THE AUTHOR IF YOU USE THIS CODE
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

INPUT:
S = delimiter separated string
Delimiter = ',' is default. => This assumes a CSV String.
The user could choose any characher as the delimiter.

OUTPUT:
A = array

EXAMPLE:
S = array2str(A,Delimiter);

Cite As

Sugato (2025). Delimiter separated string to array conversion | function: Array = str2array(String, Delimiter) (https://in.mathworks.com/matlabcentral/fileexchange/64101-delimiter-separated-string-to-array-conversion-function-array-str2array-string-delimiter), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2016a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Characters and Strings in Help Center and MATLAB Answers

Community Treasure Hunt

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

Start Hunting!
Version Published Release Notes
1.0.0.0

Updated Title.