Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default how can i set up rand or rand between to give only -1 or 1?

i need a function to generate either 1 or -1 using randbetween in Exce;
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 618
Default how can i set up rand or rand between to give only -1 or 1?

=-1+2*RANDBETWEEN(0,1)
--
David Biddulph

"Uesiet" wrote in message
...
i need a function to generate either 1 or -1 using randbetween in Exce;



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,688
Default how can i set up rand or rand between to give only -1 or 1?

Try this:

=CHOOSE(RANDBETWEEN(1,2),-1,1)

Biff

"Uesiet" wrote in message
...
i need a function to generate either 1 or -1 using randbetween in Exce;



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 418
Default how can i set up rand or rand between to give only -1 or 1?

"Uesiet" wrote apparently:
i need a function to generate either 1 or -1 using randbetween in Exce;


=2*(RAND()0.5) - 1

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 50
Default how can i set up rand or rand between to give only -1 or 1?

Answer:
=(-1)^Int(Rand(2)+1)

"Uesiet" wrote:

i need a function to generate either 1 or -1 using randbetween in Exce;



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 168
Default how can i set up rand or rand between to give only -1 or 1?

Couple of observations,

1 Your formula doesn't seem to work, =RAND(2) isn't correct syntax

2 Did you realise you replied to a 2 year old post?
http://groups.google.com.au/group/mi...af7728a9ad196d

Cheers
Martin



"Vijay Chary" wrote in message
...
Answer:
=(-1)^Int(Rand(2)+1)

"Uesiet" wrote:

i need a function to generate either 1 or -1 using randbetween in Exce;



  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 50
Default how can i set up rand or rand between to give only -1 or 1?

Hi Martin !! :)
Yeah, I made a mistake in the formula. It should be

==(-1)^(INT(2*RAND())+1)

How do you find out how old any post is !?

Vijay

"MartinW" wrote:

Couple of observations,

1 Your formula doesn't seem to work, =RAND(2) isn't correct syntax

2 Did you realise you replied to a 2 year old post?
http://groups.google.com.au/group/mi...af7728a9ad196d

Cheers
Martin



"Vijay Chary" wrote in message
...
Answer:
=(-1)^Int(Rand(2)+1)

"Uesiet" wrote:

i need a function to generate either 1 or -1 using randbetween in Exce;




  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 168
Default how can i set up rand or rand between to give only -1 or 1?

Hi Vijay,

I just did a Google Groups search for the subject line...
how can I set up rand or rand between to give only -1 or 1?

Which returned nothing so I cut it back to...
how can I set up rand or rand between

And there it was...

You can find Google Groups by going to the Google
homepage and clicking on the more dropdown at
the top of the page.

Cheers
Martin


"Vijay Chary" wrote in message
...
Hi Martin !! :)
Yeah, I made a mistake in the formula. It should
be

==(-1)^(INT(2*RAND())+1)

How do you find out how old any post is !?

Vijay

"MartinW" wrote:

Couple of observations,

1 Your formula doesn't seem to work, =RAND(2) isn't correct syntax

2 Did you realise you replied to a 2 year old post?
http://groups.google.com.au/group/mi...af7728a9ad196d

Cheers
Martin



"Vijay Chary" wrote in message
...
Answer:
=(-1)^Int(Rand(2)+1)

"Uesiet" wrote:

i need a function to generate either 1 or -1 using randbetween in
Exce;






  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default how can i set up rand or rand between to give only -1 or 1?

If you are using Microsoft's web interface at
http://www.microsoft.com/office/comm...g=en&cr=USeach thread is labelled with the date of the most recent message. If you usethe + button to expand the thread, the date of each message on the thread isshown.If you use a newsreader such as Outlook Express, the date would appear bydefault in the Sent column.--David Biddulph"Vijay Chary" wrote in ...... How do you find out how old any post is !? Vijay "MartinW" wrote: Couple of observations, 1 Your formula doesn't seem to work, =RAND(2) isn't correct syntax 2 Did you realise you replied to a 2 year old post?http://groups.google.com.au/group/microsoft.public.excel.worksheet.functions/browse_thread/thread/eca2b44b1463a48a/c8af7728a9ad196d?hl=en&lnk=st&q=how+can+i+set+up+r and+or+rand+between+#c8af7728a9ad196d Cheers Martin "Vijay Chary" wrote in message ... Answer: =(-1)^Int(Rand(2)+1) "Uesiet" wrote: i need a function to generate either 1 or -1 using randbetween inExce;

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Totals of calculated field in pivot table give incorrect results Jake Excel Worksheet Functions 6 January 12th 06 06:15 PM
how do i get my spreadsheet to give me tank gage amounts. tankerman Excel Worksheet Functions 3 January 5th 06 04:35 PM
Is there any way to give an dynamic name for a range? salut Excel Discussion (Misc queries) 1 December 7th 05 02:05 PM
The right click on my mouse does not give me the option to paste Mouse Trouble Excel Discussion (Misc queries) 3 November 23rd 05 05:36 PM
How do I give permission for certain functions in excel in locked. tradinoncoffee Excel Worksheet Functions 1 January 2nd 05 06:52 PM


All times are GMT +1. The time now is 09:01 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"