View Single Post
  #1   Report Post  
uriel78
 
Posts: n/a
Default help with a scatter graph of conditioned values

I'm a big newbie in matter of charting and vba...I hope somenone can help
me....here is my problem

I need to plot a XY scatter graph.
X and Y data values are mutually dependents one each other and they change
under an extra condition that I want to represent qith a macro control.

Hmmmm...let's try to give you an example:
first of all I need to define EXTRA CONDITIONS as follows

name S
A 1
B 1,15
C 1,20
D 1,25
E 1,35
..... .....
My goal is to have a control in cell C1 that traduces "if 'name'=A then
'S'=1, if 'name'=B then 'S'=1,15" and so on for cells A3...An

After doing that, I need to plot my XY function(s) as follows:
X Y
0 ..
1
2
3
4
5
6
7
8
9
10

X is a column made by intervals of limited values
if 'name'=A then X=(0,1,2,3,4,5,6); (7,8,9,10)
if 'name'=B then X=(0,1,2,3,4); (5,6,7,8,9,10)


Y is a function of X values:
in the case of 'name'=A
for X =0..6 Y=S*cos(x)
for X=7...10 Y=S*sin(x)

in the case of 'name'=B
for X =0..6 Y=S*cos(x)
for X=7...10 Y=S*sin(x)


Please help me with a macro...every suggestion will be very precious...I'm
struggling with excel...:-(