how to write if condition to include more options

genetist

Board Regular
Joined
Mar 29, 2013
Messages
75
Office Version
  1. 2016
Platform
  1. Windows
Hi to all, i need help in solving my problem,
My data looks like this
i.d m1 m2 m3 m4 O1 O2 O3 O4
p1 aa gg -/- z/z mono poly poly poly
p2 aa aa tt cc

i written if condition like this in blank O1 cell =if (P1=P2,"mono","poly") and i got mono for m1 in O1 cell,poly in O2 cell,poly in O3 & O4 for m3 and m4 cell values, but i want to give mono for m3 and m4 values (-/-,z/z) in O3 and O4 columns. -/- and z/z are the type of missing values thats the reason i want to give them as mono.

my output looks like this
i.dm1m2m3m4O1O2O3O4
p1aagg-/-z/zmonopolymonomono
p2aaaattcc

<TBODY>
</TBODY>
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
How is your data laid out exactly?
Thank you andrew for spending your time to help me.
before i am giving mono title for observations p1 and p2 if they contains same letter ex p1=gg and p2=gg but now i want to give mono tilte if any one of these p1 or p2 contains Z/Z or -/-. thats all i want

Thanks in advance,
Regards,
Genetist
 
Upvote 0

Forum statistics

Threads
1,214,630
Messages
6,120,634
Members
448,973
Latest member
ChristineC

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top