help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: regexprep resolve a comma value from a string


From: Nicholas Jankowski
Subject: Re: regexprep resolve a comma value from a string
Date: Fri, 9 Jun 2017 06:31:20 -0400

On Jun 9, 2017 6:25 AM, "hxchrist123" <address@hidden> wrote:
Hallo, i stuck at the following problem.
I have a Output-cell wich has the following form:

Output{8}=real:temp:297,15

My goal is to have just the value of 297,15.
With
Temp=str2num(regexprep(Output{8},'\D+', ''));
i got just the numbers 29715.
The comma is deleted. How I can I resolve the complete comma number?

Thank you.


You're finishing with a str2num. I don't think that will ever output "num,num". What sort of output do you want, a string? Or a number? Or a 1x2 number array? Or...?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]