Multiple Graphs In Excel Using VBA
Apr 3, 2012
I am currently working through data received from several experimental runs I have done for my masters studies (In chemical engineering). I need to create a chart for every experiment but coding the macro to do that has been near impossible. I have the file with the first graph drawn but I dont know how to post it.
I know it will be possible to draw every chart by hand but I am waiting on another 300+ data sets and then the amount becomes crazy.
View 4 Replies
ADVERTISEMENT
Feb 12, 2014
i have attached a sheet where I have 4 graphs on one sheet. I prefer this to an overlay. I would like to add a 5th graph but it would make all the the graphs too small. Is there a way to make the graph background longer. For instance, extend the length of this so that I can put multiple graphs on it and then just scroll from top to bottom to review them? Also, how do I copy and paste these individual graphs into a newly created graph. copy/paste doesn't work on these?
Boiler.xls‎
View 1 Replies
View Related
Jan 10, 2014
I have a perfectly working pivot table and I would like to make some graphs based on the report filter. My report filter has 4 categories, with each more than 10 sublevels.
When I make one pivot graph/chart, this goes fine, the data is ok, and I am happy. But one I make a second, and thus adjust the report filter, the first graphs changes according to the filter. I dont want that to happen
Ultimately I would like a powerpoint presentation with multiple charts, based on one table, with different report filter filters. Updated ONLY on the values, not the filter.
View 4 Replies
View Related
Mar 6, 2007
I currently have a 70 page spreadsheet with similar data that needs representing in pie chart format. All the column headers are the same and I only need 2 columns (A and T).
There are however different numbers of rows. Is it possible to write a macro to detect the number of rows before it draws the relevant pie chart (I've managed the pie chart bit!!)
See attached example, same concept but cant post real data.
View 9 Replies
View Related
Jan 4, 2012
I am trying to copy a group of six graphs from one Sheet "Charts" and paste them in another Sheet "FinShots" in the same Workbook. I have grouped the graphs and named the group "FinShots1".
But I can't seem to write a code that will copy group "FinShots1" from "Charts" and paste in "FinShots".
View 2 Replies
View Related
Nov 5, 2009
I would like to create 2 graphs for each set of data in my worksheet. the first set of data that I would like to create a 2D line chart for is in cells AQ3:AS19 (not sure if that is the correct syntax??) and the second is AW3:AY3.
I would like to position the first chart (top right corner) at BA3 and re-size it so that it is 17 cells tall and 7 cells wide. the second chart should be positioned at BI3 and the same dimensions.
I would like to delete the chart legend for both graphs
then I need to repeat about 1000 times. Each new set of data starts 20 cells lower (ie. AQ3, AQ22, AQ41..). Or every time "Band" is found in column AP.
View 4 Replies
View Related
Jul 20, 2007
see attachment.
I am looking a macro that will create as many graphs as there are counties (column a) in the data range (A4:N89 for this example). There could be a maximum of ~3000 counties, which would place the data range at roughly excel's limit (A4:N65000).
In any case, the graphs would take data from column F and look like the 3 graphs i have provided in the attachment. The graphs are simply graphing share for the top 25 lenders in each county. So, for example, Texas contains 254 counties--I would like a macro that creates 254 graphs, one next to the other, starting at cell O4 through column IV4 and then repeating at O22 through column IV22 and so on, until all the graphs for each county in the data range are created.
Also, would it be possible, just as in the attachment, for the macro to change the color of the data bar associated with a particular lender, in this case JPMORGAN CHASE BANK? In the attachment, I made the three bars associated with JPMORGAN CHASE red. If there is a county in which this particular is not in the Top 25, then all of the bar colors in the graph remain blue.
Would it be possible to do the exact same (macro that graphs off the pivot table) but include the data for the Top 25 Totals, Non-Top 25 Totals, and the County Total?
In other words, the graphs would look exactly as they do now, but, for example, the first graph would contain data from F5:F32 rather than just from F5:F29. Furthermore, the graph's axis label would pull from C5:C29 AND B30:B31 AND A32.
View 3 Replies
View Related
Sep 4, 2007
I'm pretty much a novice at Excel so obviously my knowledge is fairly limited. Basically I have created 2 sheets called 'Week 1 - By Day' and 'Week 1 - By Campaign'. The first sheet (By Day) contains data which supplies graphs to not only that sheet but also to sheet 2 (By Campaign). Sheet 2 (By Campaign) only contains graphs sourced from data within sheet 1.
So, I need to copy both of these 52 times (for every week of the year). That’s 52 x sheet 1 and 52 x sheet 2.
I have been able to copy sheet 1 easily enough by holding down the Ctrl button and dragging the sheet. This works fine and the formula and graphs within the sheet change automatically. However, the major problem at the moment is sheet 2(sheet 2 only contains Graphs which is related to data from sheet 1). When I do the same thing with sheet 2 (hold down Ctrl and drag) the graphs within the new sheet (sheet 4) are still sourcing the data from sheet 1 instead of sourcing the data from Sheet 3 'Week 2 - By Day'.
View 9 Replies
View Related
May 6, 2014
I have an excel that gets updated monthly for reporting. The goal is to get the graphs to update automatically by linking them from excel into power point. This is relatively easy but what when I go to update the report for the next month the data for the old power point changes as well. Is there a way to prevent this?
View 1 Replies
View Related
Jan 6, 2014
Excel 2012 user.
I am trying to create two vertical axis bar graphs with the Primary axis for period Q1 to Q4 and the secondary axis for FY. I have attached what I have done so far and have successfully converted all but one FY bar graph to secondary axis. Once I try to select the last one (dark gray bar called "2011 FY" on the very far right), the FY bars disappears.
My main purpose is to get both Q1-Q4 & FY on the same graph and the reason I plotted FY on the secondary axis is because I didn't want the FY $ scale to massively skew the entire graph.
Sample Report 06JAN14 - Bar graph with two axis.xlsx
View 5 Replies
View Related
Aug 6, 2007
I am trying to use VB to create 50 charts each with 3 lines using data from 3 different excel spreadsheets in the same workbook. I am able to create one chart with 3 lines using data from the three spreadsheets, this is good. However I exprience problems when i try to insert a loop to create 50 charts that correspond the the rows in each spreadsheet. I am new to VB and am very inexperienced with VB. In each worksheet my data is arranged in rows. row 1 of each worksheet has the header information and rows 2 through row 50 have my corresponding data. for example A2 lists the name and F2 through T2 lists the data. I have tried a bunch of different things but nothing seems to alllow me to be able to create multiple charts which correspond to each row of data?
Sub Chart2PPT()
Dim arow As Integer
Dim acol As Integer
Dim StartPoint As Integer
Dim EndPoint As Integer
Dim rStartPoint As String
Dim rEndPoint As String
StartPoint = 2
EndPoint = 4
For arow = 2 To 5
rStartPoint = "f" & StartPoint
rEndPoint = "t" & EndPoint
Charts.Add
ActiveChart.ChartArea.Select
ActiveChart.ChartType = xlLine 'Type of graph........................
View 2 Replies
View Related
Sep 5, 2012
I want to prepare a graph / chart for the column A and column B. Column A has headers and B has the data that I want to represent in the graphs. The real problem in this is that the two columns length is not fixed. For eg. for January Column A & B could have 5 rows of data but for February they could have 10 rows of data. I dont want to prepare the chart manually every month. I want that if we could apply any VBA coomands that could prepare the chart automatically irrespective of the rows count.
View 9 Replies
View Related
Jun 26, 2008
I need to make a macro that creates a specified number of graphs depending on the file's number of data sets. I know the number of sets that are in the data, and I know the number of data points that were taken. Here is what I have:
Sub Graphs()
Dim Startpoint As Integer
Dim Endpoint As Integer
Dim count As Integer
Dim xStart As String
Dim xEnd As String
Dim NumberSets As Integer
Dim yStart As String
Dim yEnd As String
Dim DataSet As Integer
Dim Data
Startpoint = 11 'The first set always starts in row 11
Endpoint = Range("L4").Value + 10 'Thefirst set always ends after the value of L4+10
NumberSets = Range("L7").Value 'number of times I need the loop to work
count = 1..........................
View 2 Replies
View Related
Apr 27, 2013
I am using Excel 2010 to create a simple chart. When I enter the information, highlight it and select a chart, the chart area appears blank. It doesn't matter what kind of chart I choose- it still appears blank. I've tried going into the Advanced options and indicating for All objects to be shown and that didn't work.
View 1 Replies
View Related
Jul 14, 2014
Plotting of bar and line graphs given an arrays of x and y values in VBA? I want to plot the rDateRange and rOEERange.
Code:
Dim rInitialDate As Range, rFinalDate As Range, rDateRange As Range, Calculation As Worksheet
With Worksheets("Calculation")
Set rInitialDate = .UsedRange.Find(What:=DateValue(InitialDate), After:=.Cells(1, 4), LookIn:=xlFormulas, LookAt:=xlWhole, SearchDirection:=xlNext, SearchFormat:=False)
[Code] .........
View 2 Replies
View Related
Jul 6, 2014
I've been trying to get a graph that looks like the image below for a while now and can't seem to get it to appear how I want. I am looking to duplicate it exactly, but the issue I'm having is getting the individual bars to be separate and appropriately spaced.
[URL] .....
View 7 Replies
View Related
Mar 26, 2014
There were 2 macros. One printed all of the defined ranges (40) on separate pages, and the other printed all the graphs ("charts" - 39) on separate pages. I tried to combine the VBA code to print each range and then the corresponding graph. Everything is still on separate pages, but it saved time because I didn't have to collate after printing. It seemed to work. Then I tried figure out if I could print them all to a specific tray of the printer as set in the workbook or as the printer default. Now both the combined macro and the original macro are giving errors.
Is the code I have correct to do what I am trying to do (print each range and then the graph all on separate pages)? Is there any way to put the output tray choice into the macro?
Sub Load_Data_Report()
'
' Load_Data_Report Macro (print all tables & graphs)
' Macro recorded 12/21/00 by xxx
'
' Keyboard Shortcut: Ctrl+j
'
[Code] ........
View 1 Replies
View Related
Apr 14, 2014
I've been using a VBA code to look through my spreadsheet and find any graphs in any tab and move it to powerpoint. I have about 70 tabs with 7 graphs each.
I have is that the order of the graphs in the slidepack isn't in the same as found on each excel tab.I also tried renaming them (chart1-chart7) but problem still remains.
View 3 Replies
View Related
Dec 27, 2012
I have a simple reporting sheet where the data for orders place is in one sheet and on the other sheet is an imput box for 'date' and it filters through and presents a table of data and two graphs for the date chosen.
I give a daily report (contents of this sheet) but I also need to leave this sheet available for anyone to open and change to another date.
I want to copy the repor sheet into a new one and email but I want the graphs to remain, not go blank when anyone changes the original sheet.
Excel 2007 / Windows 7.
View 3 Replies
View Related
Jan 1, 2008
I have about 30 sheets with 500+ rows of data in each, with each row of data in the sheet needing to be plotted individually against the same y values. Is there a way to automate this with a macro? I have recorded a macro for an individual graph but don't know how to tell it to loop and go to the next row of data for the x values while keeping the y values constant.
View 3 Replies
View Related
Mar 20, 2007
How can I make batch changes to graphs in the same excel workbook (but on different worksheets?)?
In particular, if I have a bunch of graphs, how can I make bulk changes to color, size, axes titles, etc.?
View 9 Replies
View Related
Nov 21, 2008
I'm currently struggling with Excel 2007 and I need to produce a seriation graph. I've searched the web and did a search here and no luck.
Is it even possible to graph data using the a seriation graph in Excel?
If so, How?
View 8 Replies
View Related
Dec 7, 2009
I have created a series of numbers using a column 'n' and 3 cells for Start value, End value and increment, this is thwe formula: .....
View 9 Replies
View Related
Dec 18, 2011
I am creating a spreadsheet system for storing school grades, and I have a sheet on my system which shows graphs of the students data, and on this sheet there are rather a lot of graphs, and its sort of a visual overload to see so many graphs on one sheet. Im just wondering if there is any thing which I could insert which would give the person using the system a choice of which class's graph they want to show.
View 1 Replies
View Related
Mar 16, 2007
how do i size column graphs equally? so one graph doesn't look bigger then another... or out of place compared to the other column graphs i have...
View 9 Replies
View Related
Feb 23, 2008
I have sort of a weird request. I've got a chart with data on a patient with a sleep disorder and was hoping to create some charts based on the information I've gathered. For example, I've got a column with the amount of time before she falls asleep and another column with a type of food listed. I want to see if there's any correlation between these two variables. What would be the best type of graph to do this, and what formula would I use?
View 9 Replies
View Related
May 3, 2006
I am making an excel program that performs a series of complex calculations then produces several charts of the output. I have the output in a table of a known lenght and width. The problem comes when attempting to create the graphs, I first delete all the old graphs and make new ones. Then I try to add the series to the graphs. I want the graph to be one column vs another column but I have only been able to get it to graph a column vs 1, 2, 3, ect.
how to set the x-axis source data for a given series.
View 9 Replies
View Related
Jun 15, 2006
I have two seperate graphs in two different workbooks. Both graph's are identical in the setup, they have the same X axis and Y axis value. They are identical in every way except for the varying in percentages. This graph was originally setup in that it would calculate the results for a period of a week at a time. Is there a way to merge the two graphs thereby showing the results for a two week period?
View 4 Replies
View Related
Jun 30, 2006
I'm trying to make alot of graphs(400) and I'm not really sure where to start but here with what I've got so far.
Sub macro2()
Dim x As Long, t As Long, y As Long, z As Long
y = 3
z = 5
x = 4
While x < 1000
With Worksheets("cabernet (2)")
t = Cells(x, 1).Value
Charts.Add
ActiveChart.ChartType = xlLineMarkers
ActiveChart.SetSourceData Source:=Sheets("cabernet (2)").Range("By:Hz"), PlotBy:=xlRows
ActiveChart.Location where:=xlLocationAsObject, Name:="Cabernet (2)"
ActiveWindow.Visible = False
ActiveChart.HasTitle = True
ActiveChart.charttitle.Text = " " & t
Windows("complete Favorite Genes.xls").Activate
y = y + 3
z = z + 3
x = x + 4
End With
Wend
End Sub
I don't really know if putting a variable directly into a range works, so far it doesn't.
As you can tell I need a line graph of the range B3:H5, then the next is the those same columns but 3 rows down, so the next graph is at B6:H8. I'd also like to through in a title here, but I may just be playing with fire. The title is located in column A starting at 4 and corrosponds with each graph, so it too goes is increments of 3, i.e., the first title is at 4 the second at 7 the third at 10. Somebody help me out this isn't working very well at all.
View 5 Replies
View Related
Jul 8, 2014
I have a data which has a start time, end time, Stay Time(End-Start) and # of subjects. I am trying to create a graph, line, bar or histogram which shows how many subjects were there at a specific time. So the horizontal axis would have time from 00:00 to 24:00 and vertical axis would have the total # of subjects or the %.
Start End Subject Stay
01:00 02:00 1 01:00
01:00 01:45 1 00:45
02:00 21:00 1 19:00
03:10 14:10 1 11:00
The data set is huge(27000 rows) and I am using excel to create a graph.
I have tried using line plots and bar charts(stacked) but couldn't. I am not sure if there is an easier way to do it .
View 4 Replies
View Related