Plot Each Selected Row Range As Series In Scatter Chart

May 16, 2008

I need to plot multiple series in a scatterplot. The problem is that the number of series is user-defined. And also, the number of data poitns in each series is different. I've looked it up already, but a lot of the examples i've seen don't account for the fact that I need to run through a loop and add series into my graph.
In other words, i need a way to select a certain range each time it runs through the loop, and add the data as a series into the chart. Also, the user enters how many series there are, so I use that as a counter

View 9 Replies


ADVERTISEMENT

Scatter Plot Chart With Multiple Series From Selected Range

Jan 31, 2009

What I want to achieve is a script that would create a new scatter plot of multiple series from a selected block of cell. I found a thread that was similar but what is different from my data is that my x values are different for each series.

The format of the data is in the following format, the first series will the first x,y pair, the 2nd series would be the second x,y pair. I don't know if it'll be an issue but one thing is that the date might be different lengths. For instance, the 3rd series, only has 4 data points, whereas the other series contains 6 data points?

x0.200.400.600.801.001.20
y5.002.501.671.251.000.83
x0.100.200.300.500.701.30
y5.002.501.671.000.710.38
x0.100.300.400.50
y6.672.221.671.33

So essentially, is there a way I can have the script say, select your range, and then graph the selected range as a scatter plot?

View 9 Replies View Related

Spurious XY Scatter Chart Series Adding Series

Aug 21, 2006

The following code is supposed to produce six series on an xlXYScatter chart. It produces seven with the seventh series being a repeat of the sixth but named series 7.

Sub Chart2()

Dim DataRange As Range
Dim CellString As String 'Stores a cell range in the form "AA27:AB39"
Dim CurrentSeries As Integer
Dim SeasonCount As Integer

Worksheets("Hemisphere").ChartObjects(2).Activate

CurrentSeries = 1 ............

View 9 Replies View Related

Formatting X Axis On Scatter Plot Chart

Jul 27, 2007

Attached is a chart I am trying to create. So basically, I originally used a line chart but it didn't have the flexibility of the scatter chart, but i am having a very hard time formatting the X axis. First of all - I would like the line in the middle at the 0% point to actually go to the bottom so that the x axis labels aren't in the middle of the graph. Second the x axis labels aren't showing up correctly. They should be quarters: 1Q:02, 2Q:02, 3Q:02, 4Q:02... Finally, how can I show the correlation between these two data points plotted - the R-squared. THANKS!!! Auto Merged Post;I actually was able to figure out most of what I asked. What is remaining: how do I calculate the R-Squared on the chart? Isn't there a way to do it automatically in excel on the chart.

View 3 Replies View Related

Label Chart Scatter Plot Markers

Jun 4, 2008

In the attached spread sheet I have created a scatter plot. How can I label each of the markers with its appropriate label from Column A - the Company Ticker. When I right click to show data labels it brings back the incorrect column. Also is there a way once the labels are brought in to put them in the circle and so that the chart doesn't look too clumped together.

View 2 Replies View Related

Conditional Data Point Colors For Scatter Plot Chart

May 5, 2008

I have to create a chart XY Scatter plot in excel. I have to differentiate the data points color based on the another column "category". Now I can change the data points color manually. Since the number of points is huge, is it possible to color the data points based on a column?

View 5 Replies View Related

Delete All Series In XY Scatter Chart

Aug 1, 2006

I am using the following code to delete all of the series in the chart. It is give type mismatch error.

Sub allchannelchart()
Dim i As Integer, s As SeriesCollection
ActiveSheet.ChartObjects("allchan").Activate
'ActiveChart.PlotArea.Select
For Each s In ActiveChart.SeriesCollection
s.Delete
Next s

View 2 Replies View Related

Format Chart Plot Series/Axis

Jan 16, 2007

im having problem formatting my graph.

chart type = line.

I have 1 series of data, which is N values vs. Time.

Time however, is specified by specific dates. The graph is not putting a plot point accorrding to the date corresponding to the N value.

Example values:

date:____1/1/05 _______ 5/7/05 _____ 8/13/05
n value: __55 ___________ 22 _________ 11

I want the chart to reflect the time between the dates and put a plot point (n value) under each date listed and connect with a line.

View 9 Replies View Related

Plot Multiple Series In 1 Graph/Chart

Aug 18, 2006

how can i plot multiple series of values in one graph after checking some check boxes, which i have previously done, randomly?

View 4 Replies View Related

Macro: Plot Graph/Chart By Series Of Rows

Jun 30, 2008

I've been trying to work out a code for a while now to plot some series in rows on a graph. The wonderful Mr Pope helped me with one before but for series in columns but i just don't seem to understand it enough to use it for this problem. the graph already has 2 series plotted (called the envelope) so i have to use seperate series to plot the data.

Basically the name of series is down column A
but the range is from E1 to Y1
and the data to be plotted on the graph which already has two series plotted in it is E2 to Y2, E3 to Y3 etc. iv been trying to use this code but failing miserably

Sub adddatatopsd(Name As Range, XData As Range, YData As Range)
With ActiveSheet.ChartObjects(1).Chart
With .SeriesCollection.NewSeries
.ChartType = xlColumnClustered
.XValues = XData
.Values = YData
.Name = Name
.ChartType = xlXYScatterSmooth
End With
End With
End Sub...........................

View 4 Replies View Related

Plot Chart From Selected Data

Nov 9, 2006

I have a large amount of data recorded from a logging device which i then need to convert to a graph. Is there some nice coding to enable the user to select a range of dates from column A and times from column B then allow the user to select the column in which relevant data is contained and plot a line graph of the data contained with named axes.

View 9 Replies View Related

Interval Distribution Plot Chart/Graph From Selected Row

May 9, 2008

I have several worksheets with thousands rows (independent variables) and hundreds columns (all dependent variables). Each line basically gives me hundreds values for each independent variable - see below:
...
C9 39.65 653.95 5.28 163.56 99.56 14.49 ... ...
E9 7535.92 21500.56 2835.88 3122.98 7225.34 5371.25 ... ...
G9 111568 298021 12940 31645 181797 36996 ... ....
...

I need to know how the values in each row are distributed, and I ideally plot a 2D column graph of the distribution. Is there a way to do that and create/program a macro (with relative button on the workboook) that does it automatically once clicked?

Very often there are outlying values (bigger or smaller by a factor of 1000 or even more), mistakes, which I would like to identify and fix possibly.

View 9 Replies View Related

Determine Selected Series On Chart?

Mar 26, 2014

Is there a way of determining the series that has been selected on a chart?

View 3 Replies View Related

Scatter Plot With Line Best Fit

Feb 2, 2008

I got the following table and it generates a random number either 1 or 0 (win or loss)

trade win/loss Account value
0 10,000
rand() 1 0 9,800
rand() 2 1 11,000
rand() 3 1 12,000
rand() 4 0 11,500

Each time I press F9, the Account value changes because the win/loss is generated randomly. Assuming, I press F9 100 times, how do I create a scatter plot chart with a best line fit for all the account values. I know how to create the scatter plot but how do I save all the values everytime I press F9.

View 9 Replies View Related

Chart/Plot Changing Range

Oct 24, 2006

I have a chart updating on a weekly basis

a) can i select a whole range without the chart picking up any blank cells or zeros, if so then a lot of my other question will be redundant

b) I only want to show 4 weeks at a time, so when a new column of data is added on, how do i get VBA to shift the range accross 1 to the right e.g.

week 36 37 38 39
Shift to
week 37 38 39 40

View 5 Replies View Related

Plot Chart With Dynamic Range

Jun 27, 2008

I maintain data which gets updated every week. I have a chart associated with this data which I want to get updated automatically. I tried to use dynamic range on the chart and it kinda works. But the issue with my data is that I have data set in a row, followed by a blank cell which is then followed by average of last two weeks. Hence, when I use a dynamic range, it also displays the last value in the row (average), which I don't want to display in my chart.

So what I am looking forward to do is set up dynamic range or any other solution, which automatically updates my chart with weekly sales data without showing the average value in the chart. I have attached sample worksheet here.

View 4 Replies View Related

Labeling Points On Scatter Plot

Oct 8, 2013

I have the scatter plot below and I'd like to get the team names to show beside each point.

View 3 Replies View Related

How To Plot Scatter Graph With Regression

Nov 20, 2013

Given 100 samples, to calculate: numbers of hours spent on study is dependent on numbers of hours spent on social networking site.

x (social networking site)
y (study)
x^2

xy

6
4
36
16
24

[Code] .......

SUMMARY OUTPUT

SUMMARY OUTPUT

Regression Statistics

Regression Statistics

Multiple R
0.571423290877713

[Code] ....

So, I've got the coefficient of correlation equals to 0.57, how can I plot my scatter graph?

View 1 Replies View Related

Macro To Edit Scatter Plot?

May 15, 2014

I have a list of interest rates and durations and was hoping to be able to add in a third dimension of data which would either increase the size of the plotted points or change their colour depending on the rating. So have the normal scatter plot then save me from editing each point manually.

i.e.

A1
B1
C1
D1

Interest Rate
Duration
Rating

3%
3.5
A+

[Code] .........

View 1 Replies View Related

(x,y) Scatter Plot Label Vba Implementation

Sep 2, 2004

I have a scatter plot with 150 points closely grouped. Enabling the label option clutters the graph. A cleaner way would be to hoveri the mouse over a data point and pop-up a box displaying it's value (x,y) as well as a label contained in an adjacent column.

Details:

The default functionality is that when the mouse hovers over a particular point the yellow pop-up box appears withData set label
Data point name "x"
Data point (x,y)
and one can choose to show "label-name-point" or just "point" by accessing the Tools-Options_Charts menu item. What I would like instead is to hover the mouse over a particular point and get the yellow pop-up box with the following functionalityData set label
Data point name "label"
Data point (x,y)
where the label is contained in an adjacent column in my data spreadsheet.

I read a post by Andrew Poulsom that stated it is probably not possible to customize the yellow pop-up baox and then offered some vba code to allow a mouse click to bring up a label. I was wondering how to implement this code in the spreadsheet. Also, does the graph have to be embedded in the worksheet "as object in", or can I use "As new sheet"?

View 9 Replies View Related

Creating Scatter Plot With Mean/ SD Error Bars

Apr 24, 2014

I need to create some vertical scatter plots ie where all the y values are in the same line, and also to put on the mean and standard deviation error bars, like the example I found below. I have managed to plot the scatter by giving all the y values in each group the same x value, but I don't know how to proceed.

View 4 Replies View Related

How To Change XY Scatter Plot Data Labels

Jan 22, 2014

I need to label points on an XY scatter plot with a different set of label points than those provided by simply assigning data labels (don't need series name or x and/or y values displayed but an additional field of data). I can't use an add in (work machine) and would like to do this without using macros.

The project has 4 fields

A B C D
plot# type x y

I need to label the XY points for each series (type) by their plot #. The attached image/file shows what I'm looking for (added plot # labels manually for sake of display, in reality there are >2000 plots so I cant do it manually.

View 1 Replies View Related

Draw Parallel Line Through Scatter Plot

Oct 6, 2009

Currently we have data that is plotted to a scatter plot along with an already defined line. Next, with a straight edge we attempt to draw a line parallel to the already defined line through the scatter points of data. We basically find two points that give us the best fit to the original line. What I attempted to do was calcualte the slope of the original line and then the slope of each combination of two points in the data set. I then subtracted the slopes, found the minimum difference and thought that would give me the line most parallel to the original. This doesn't seem to work. I'm at a loss, any advice?

View 8 Replies View Related

Calculate Volume From Two Datasets On Scatter Plot

May 8, 2012

I have two different data sets that I have plotted using XY(Scatter) w/ smooth lines. Is there a macro or sub that will calculate the volume or area between where the two data sets cross?

View 3 Replies View Related

Use CurrentRegion As Source Data For Scatter Plot?

Mar 1, 2013

I have a spreadsheet in which the amount of data is not predictable. There are always a different number of rows and columns in this spreadsheet. I need to be able to grab the data that is in it starting with B1 and going to the last row and column with data and put it into a scatter plot. The code that is currently in my macro is as follows:

ActiveSheet.Range("B1").CurrentRegion.Select
ActiveSheet.Shapes.AddChart.Select
ActiveChart.ChartType = xlXYScatterSmoothNoMarkers
ActiveChart.SetSourceData Source:=Range("ForChart!$B$1:$J$1000")

Note: ForChart is the name of the sheet where the data is housed; I have other sheets in this macro.

I know that the last line is the problem. While I figured out how to select only the data I need, when it goes to put it into the chart, it's still using an absolute reference and I don't want that. There are sometimes more columns than J and fewer rows than 1000. I want that data range to be whatever CurrentRegion selected. Is that even something that Excel can do?

View 3 Replies View Related

Creating Custom Legend For XY Scatter Plot?

Sep 30, 2013

I need a way to make a customized legend for a scatter plot, is there any way to do that through VBA? I have a scatter plot with some points highlighted green, and some points grey depending on the user selection and need to be able to create a legend based on what the user selects (e.g. Green - Category B, Grey - Category A, etc.).

For some reason I can't get Excel to rename points on the scatter, so I feel like there is only one option: create custom images and align them correctly with labels on the plot.

View 2 Replies View Related

Data Labels Points In Scatter Plot

Jun 19, 2008

I am attaching the Excel File along with this mail. In chart there is data points have been mentioned in scatter plot like (38,15 etc) Instead of these points I want the names that I have mentioned in column A2:A9. I used to make lots of charts related to this and it is very diffilcult for me to manually punch all these names and most importantly the thing is that I cant download the software available on http://www.appspro.com due to some issues can you give me the VBA code for this which will automatically paste these names only I have to change is the data range and its very urgent................ASAP

View 7 Replies View Related

How To Add Date Labels And Have Different Color Points For Scatter Plot

Sep 15, 2014

What I'm aiming to be able to do is have a scatter plot that displays date labels for each point as well as distinguish the points by year by using different colors. I found a VBA code for scatter plot date labels and I also realize that (for me at least), the easiest way to distinguish the years by color would be to separate them with a logical statement and let the chart do the rest of the work by categorizing them as separate data ranges. However, I tried to do this with the VBA code that I found and it expectedly did not work. I'm not sure if it's an easy fix to just add more "xvalues" columns in the code or if what I want to do here is even possible.

Format and Code for the Date Labels:
Date Time
Rainfall (mm)
24 hr RDII Volume (L/ha/day)

[Code].....

View 1 Replies View Related

Attach Labels With Names To The Points In A Scatter Plot

Jul 18, 2006

how to attach labels with names to each point in a scatter plot

View 9 Replies View Related

Extract Scatter Plot With Connected By Smooth Lines Points

Jul 25, 2012

I have a couple of points, and when i do a scatter plot with connected by smooth line plot, it seems like excel does a bezier splines interpolation. I am wondering am i able to extract the data plots from the data chart?

for example if i have

X - Y
0 - 5
180 - 0
360 - 5

I would like to have all datas of Y from X (0 - 360 degree every degree).

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved