Home |
Search |
Today's Posts |
#1
|
|||
|
|||
How do I define the signum function sign(x) in Excel?
I am trying to define the function sign(x) in Excel. Sign (x) = 1 if x0,
sign(x)=0 if x<0 and sign(0)=0. I know that it is probably straightforward to do as an if statement, but I wondered if there is just an explicit function in Excel that would do it for me. |
#2
|
|||
|
|||
Hi, You could try something like this: =MAX(SIGN(A1),0) so that your number is in A1. - Asser -- Jazzer ------------------------------------------------------------------------ Jazzer's Profile: http://www.excelforum.com/member.php...fo&userid=4464 View this thread: http://www.excelforum.com/showthread...hreadid=276583 |
#3
|
|||
|
|||
Do you really mean sign(x)=0 if x<0? If not (and you meant sign(x)=-1
if x<0), then check XL help for the SIGN function. -- Regards, Tushar Mehta www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity solutions In article , says... I am trying to define the function sign(x) in Excel. Sign (x) = 1 if x0, sign(x)=0 if x<0 and sign(0)=0. I know that it is probably straightforward to do as an if statement, but I wondered if there is just an explicit function in Excel that would do it for me. |
#4
|
|||
|
|||
Jonathan,
=IF(x0,1,0) HTH, Bernie MS Excel MVP "Jonathan" wrote in message ... I am trying to define the function sign(x) in Excel. Sign (x) = 1 if x0, sign(x)=0 if x<0 and sign(0)=0. I know that it is probably straightforward to do as an if statement, but I wondered if there is just an explicit function in Excel that would do it for me. |
#5
|
|||
|
|||
The sign function is in Excel, but you defined something
like: =--(A10) Regards, Bernd |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? | Excel Discussion (Misc queries) | |||
Access Module coded converted to Excel Function | Excel Discussion (Misc queries) | |||
Excel function help facilities | Excel Discussion (Misc queries) | |||
I cant use englisch function names in a swedich version of excel | Excel Discussion (Misc queries) | |||
Statistical Excel Function Question within Excel 2000... | Excel Worksheet Functions |