Notices
Northeast Region Includes CT, MA, ME, NH, NJ, NY, PA, RI, VT.

Worcester/Boston Social Thread

Thread Tools
 
Search this Thread
 
Old Sep 22, 2008 | 10:45 AM
  #19276  
EvoBroMA's Avatar
Evolved Member
 
Joined: Feb 2006
Posts: 1,345
Likes: 1
From: MA


Old Sep 22, 2008 | 10:46 AM
  #19277  
Paulnsx's Avatar
Thread Starter
Evolving Member
iTrader: (7)
 
Joined: Jun 2007
Posts: 359
Likes: 0
From: Northborough, MA
i enjoyed the first one dexter.
Old Sep 22, 2008 | 10:50 AM
  #19278  
DocCola's Avatar
Evolved Member
iTrader: (4)
 
Joined: Apr 2008
Posts: 1,118
Likes: 0
From: Marlborough, MA
lol on the 1st one.
Old Sep 22, 2008 | 11:02 AM
  #19279  
avengerhed's Avatar
Evolved Member
iTrader: (13)
 
Joined: Sep 2004
Posts: 602
Likes: 0
From: Marlboro, MA
Guys, I need excel help... i have data like this:

Blue1
Red1
Blue2
Red2
Blue3
Red3
Blue4
Red4

and so on...

I need it to look like this:

Blue Red
1 1
2 2
3 3


I have tried all iterations of Vlookup, offset, index, lookup, rows, etc that I can think of but i am stumped... how do you parse/collect alternating rows of data?!?
Old Sep 22, 2008 | 11:06 AM
  #19280  
KGHtheII's Avatar
Evolving Member
iTrader: (2)
 
Joined: Aug 2008
Posts: 232
Likes: 0
From: MA
Originally Posted by avengerhed
Guys, I need excel help... i have data like this:

Blue1
Red1
Blue2
Red2
Blue3
Red3
Blue4
Red4

and so on...

I need it to look like this:

Blue Red
1 1
2 2
3 3


I have tried all iterations of Vlookup, offset, index, lookup, rows, etc that I can think of but i am stumped... how do you parse/collect alternating rows of data?!?
I'm pretty lame when it comes to excel, but can u manipulate the original sheet? If so could you try sorting it by color and then running through the numbers?
Old Sep 22, 2008 | 11:09 AM
  #19281  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
Dave, you will need a macro or perl script to extract that.
Old Sep 22, 2008 | 11:21 AM
  #19282  
avengerhed's Avatar
Evolved Member
iTrader: (13)
 
Joined: Sep 2004
Posts: 602
Likes: 0
From: Marlboro, MA
I know... I am trying to write a formula or macro to extract it...

I've done (what seems to be) more complicated lookups before but this is stumping me. And to make it worse, there's really no "red/blue" in the data...it's just a HUGE string of numbers. *sigh*
Old Sep 22, 2008 | 11:22 AM
  #19283  
EvoBroMA's Avatar
Evolved Member
 
Joined: Feb 2006
Posts: 1,345
Likes: 1
From: MA
if its perfectly alternating you have to use the MOD() function. and tabulate more columns

ie: in another column =IIF(MOD(ROW(),2)=0,1,0)
this will get you part way there.
Old Sep 22, 2008 | 11:23 AM
  #19284  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
so like
1231
1241
1232
1242
1233
1243

??
Old Sep 22, 2008 | 11:25 AM
  #19285  
avengerhed's Avatar
Evolved Member
iTrader: (13)
 
Joined: Sep 2004
Posts: 602
Likes: 0
From: Marlboro, MA
Originally Posted by dexmix
if its perfectly alternating you have to use the MOD() function. and tabulate more columns

ie: in another column =IIF(MOD(ROW(),2)=0,1,0)
this will get you part way there.
Dexter, please to expand. thanks!

Originally Posted by MR Turco
so like
1231
1241
1232
1242
1233
1243

??
Yeah...it looks like

504.97
203.65
550.12
203.50
600.23
203.45

One set of data is essentially background readings and is fairly stable...the other is a signal reading and the value changes according to the chemistry we're measuring...
Old Sep 22, 2008 | 11:32 AM
  #19286  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
Originally Posted by avengerhed
Dexter, please to expand. thanks!



Yeah...it looks like

504.97
203.65
550.12
203.50
600.23
203.45

One set of data is essentially background readings and is fairly stable...the other is a signal reading and the value changes according to the chemistry we're measuring...
Well i know you can do a find and replace and remove the first x characters if they are the same. like in my example if you wanted to remove 123 you could find and replace 123 with null and it would remove all of them.

The sorting is the hard part but if you just want every other number to go to a specific cell you could do something like

Range("A1").Select
Do While Selection <> "" 'loop until it finds the last cell
selection.cut
selection.paste 'to new spot
x = x + 2
Range("A1").Offset(x).Select
Loop

something like that. I would have to formally write it of course.

Edit: the problem is that Excel is robust for a spreadsheet but elementary for a programming language making it very hard to do simple things. Parsing strings within a cell being one of them.

Last edited by MR Turco; Sep 22, 2008 at 11:37 AM.
Old Sep 22, 2008 | 11:39 AM
  #19287  
Paulnsx's Avatar
Thread Starter
Evolving Member
iTrader: (7)
 
Joined: Jun 2007
Posts: 359
Likes: 0
From: Northborough, MA
4 door lambo = UBER GHEY
Old Sep 22, 2008 | 11:40 AM
  #19288  
avengerhed's Avatar
Evolved Member
iTrader: (13)
 
Joined: Sep 2004
Posts: 602
Likes: 0
From: Marlboro, MA
Alrighty, I've got my IF/Mod statement working and I have a column next to my data of 0s and 1s...

Turco, I like your macro there, I may try to expand on that since I fear that writring all of this in a formula is going to be convoluted...
Old Sep 22, 2008 | 11:42 AM
  #19289  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
i will continue to work here
Old Sep 22, 2008 | 11:44 AM
  #19290  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
Dave i found an exercise in the book i have that i am going to try to make work.



All times are GMT -7. The time now is 04:21 AM.