Horse Racing Forum - PaceAdvantage.Com - Horse Racing Message Board

Go Back   Horse Racing Forum - PaceAdvantage.Com - Horse Racing Message Board > Off Topic > Off Topic - Computers


Reply
 
Thread Tools Rate Thread
Old 09-23-2020, 04:19 AM   #1
Achilles
Registered User
 
Join Date: Mar 2005
Posts: 121
HOW TO TREAT NEG NUMBERS AS ZEROS?

I would like to perform some arithmetical operations on a column of figures in EXCEL. How do I get the formula to treat any number which is less than zero in value, as if its value is zero?( i.e. if x<0, then x=0) I hope that someone here can help when they can. Thanks in advance................Jack
__________________
Achilles

-----Being unable to assume an initial premise with any tolerable degree of accuracy, I am loathe to assert a conclusion, fearful lest I should err.
Achilles is offline   Reply With Quote Reply
Old 09-23-2020, 10:09 AM   #2
Achilles
Registered User
 
Join Date: Mar 2005
Posts: 121
Thanks anyway, but.............

.....I figured it out using the max function.
__________________
Achilles

-----Being unable to assume an initial premise with any tolerable degree of accuracy, I am loathe to assert a conclusion, fearful lest I should err.
Achilles is offline   Reply With Quote Reply
Old 09-23-2020, 12:10 PM   #3
Dave Schwartz
 
Dave Schwartz's Avatar
 
Join Date: Mar 2001
Location: Reno, NV
Posts: 16,909
Quote:
Originally Posted by Achilles View Post
I would like to perform some arithmetical operations on a column of figures in EXCEL. How do I get the formula to treat any number which is less than zero in value, as if its value is zero?( i.e. if x<0, then x=0) I hope that someone here can help when they can. Thanks in advance................Jack
Sorry I missed this.

Very simple:
1. Column A is a column of values
10
20
0
-10
-20
50

2. Column B is created from column A using this formula:
=(A1>0) * A1
Dave Schwartz is online now   Reply With Quote Reply
Old 09-23-2020, 05:56 PM   #4
Achilles
Registered User
 
Join Date: Mar 2005
Posts: 121
Thanks for your reply Dave

I did it by using MAX(0,J2) to create a duplicate column of figs that I could plug into a formula in another column. Your formula seems pretty slick, like I could plug it right into the formula and avoid creating a redundant column. I'll give that a try later.
Thanks again for answering.................Jack
__________________
Achilles

-----Being unable to assume an initial premise with any tolerable degree of accuracy, I am loathe to assert a conclusion, fearful lest I should err.
Achilles is offline   Reply With Quote Reply
Old 09-23-2020, 06:11 PM   #5
cj
@TimeformUSfigs
 
cj's Avatar
 
Join Date: Jan 2002
Location: Moore, OK
Posts: 46,828
Quote:
Originally Posted by Achilles View Post
I did it by using MAX(0,J2) to create a duplicate column of figs that I could plug into a formula in another column. Your formula seems pretty slick, like I could plug it right into the formula and avoid creating a redundant column. I'll give that a try later.
Thanks again for answering.................Jack
Why not just plug MAX(0,J2) into the formula itself so you don't have to create another column?
cj is offline   Reply With Quote Reply
Old 09-24-2020, 09:20 PM   #6
Achilles
Registered User
 
Join Date: Mar 2005
Posts: 121
Why not...............?

Hi C.J.


Actually (RED BOARD ALERT) I did that, and guess what?..........It worked!


Thanks for your interest.................Jack
__________________
Achilles

-----Being unable to assume an initial premise with any tolerable degree of accuracy, I am loathe to assert a conclusion, fearful lest I should err.
Achilles is offline   Reply With Quote Reply
Reply





Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

» Advertisement
» Current Polls
Wh deserves to be the favorite? (last 4 figures)
Powered by vBadvanced CMPS v3.2.3

All times are GMT -4. The time now is 03:11 PM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 1999 - 2023 -- PaceAdvantage.Com -- All Rights Reserved
We are a participant in the Amazon Services LLC Associates Program, an affiliate advertising program
designed to provide a means for us to earn fees by linking to Amazon.com and affiliated sites.