Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Rounding to integers and adding plus sign
Hi, I have 2 problems
My first problem is that I have a large amount of data that I want to be rounded to the nearest integer value. What I have been using is "=INT(ROUND(Q795,2-(1+INT(LOG10(ABS(Q795))))))" to get it to 2 significant figures, and then to only take the integer value of that. It is having problems though since it will truncate numbers like 2.6 to 2 and I need them to be 3. My other problem is that I want some sort of formula to make a certain cell equal + if the number I am testing is positive... I'm not good with coding but something like If N160 then N15 = + also if you tell me the code can you please walk me through how to input that? Thanks a lot |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Rounding to integers and adding plus sign
Okay I found a way to get around the first part of my problem since it was
not needed anyway. Now all I need to know is how to make a cell equal "+" when the number in a different cell (say cell N16 is 0. If N16 is < 0 then I want the cell to equal nothing, or if that is not possible, I want it to equal "-" Thanks for any help ~Joe "Joe" wrote: Hi, I have 2 problems My first problem is that I have a large amount of data that I want to be rounded to the nearest integer value. What I have been using is "=INT(ROUND(Q795,2-(1+INT(LOG10(ABS(Q795))))))" to get it to 2 significant figures, and then to only take the integer value of that. It is having problems though since it will truncate numbers like 2.6 to 2 and I need them to be 3. My other problem is that I want some sort of formula to make a certain cell equal + if the number I am testing is positive... I'm not good with coding but something like If N160 then N15 = + also if you tell me the code can you please walk me through how to input that? Thanks a lot |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Rounding to integers and adding plus sign
Hi,
Try this in N15: =If(N160,"+","") Is this what you need? Regards - Dave. |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Rounding to integers and adding plus sign
Try this format and the numbers can be operated on.
Format, Number, Custom:= #,##0+;-#,##0 Regards Peter "Joe" wrote: Okay I found a way to get around the first part of my problem since it was not needed anyway. Now all I need to know is how to make a cell equal "+" when the number in a different cell (say cell N16 is 0. If N16 is < 0 then I want the cell to equal nothing, or if that is not possible, I want it to equal "-" Thanks for any help ~Joe "Joe" wrote: Hi, I have 2 problems My first problem is that I have a large amount of data that I want to be rounded to the nearest integer value. What I have been using is "=INT(ROUND(Q795,2-(1+INT(LOG10(ABS(Q795))))))" to get it to 2 significant figures, and then to only take the integer value of that. It is having problems though since it will truncate numbers like 2.6 to 2 and I need them to be 3. My other problem is that I want some sort of formula to make a certain cell equal + if the number I am testing is positive... I'm not good with coding but something like If N160 then N15 = + also if you tell me the code can you please walk me through how to input that? Thanks a lot |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Rounding to integers and adding plus sign
Thanks! this is exactly what I was looking for
"Dave" wrote: Hi, Try this in N15: =If(N160,"+","") Is this what you need? Regards - Dave. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how can i change dollar sign to rupee sign in sales invoice | Excel Discussion (Misc queries) | |||
Rounding to Multiples of Integers? | Excel Discussion (Misc queries) | |||
rounding down to positive when adding cells | Excel Worksheet Functions | |||
Rounding Error when adding or subtracting two cells | Excel Worksheet Functions | |||
A list of Consecutive Integers, can I search for missing integers | Excel Worksheet Functions |