Home |
Search |
Today's Posts |
|
#1
![]() |
|||
|
|||
![]()
have a large amount of measurements, about 3000.
they have a value between -10 and 10. I would like to make a bar-chart. which shows how many measurements there are between. -10..-9 -9..-8 etc. where the y axis are the number of values per interval...and the x axis are the intervals. -10 -9 -8 -7 -6 -5 etc. would like to make it as a macro. The values are in column G I have attached a file with the examples of values...column A is not formattet only text. Kim Last edited by kima : November 9th 12 at 04:29 PM |
#2
![]() |
|||
|
|||
![]() Quote:
|
#3
![]() |
|||
|
|||
![]()
I would like it to make the bar chart with a "one-click" macro.
Like the one I have for my line chart: Code:
Sub OpretGraf() 'Opretter og formatere graf With ActiveSheet.ChartObjects.Add _ (Left:=10, Width:=800, Top:=10, Height:=400) .Chart.SetSourceData Source:=Sheets(1).Range("A:A,G:G") .Chart.ChartType = xlLine 'Y-akse max og min .Chart.Axes(xlValue).MaximumScale = 40 .Chart.Axes(xlValue).MinimumScale = -40 .Chart.Axes(xlValue).MajorUnit = 5 'Text på X- og Y-akse .Chart.Axes(xlCategory).TickLabelPosition = xlLow '.Chart.Axes(xlCategory).TickLabels.Offset = 1000 .Chart.Axes(xlCategory).TickLabels.Font.Size = 10 .Chart.Axes(xlCategory, xlPrimary).HasTitle = True .Chart.Axes(xlCategory, xlPrimary).AxisTitle.Characters.Text = "Log tidspunkt" .Chart.Axes(xlValue, xlPrimary).HasTitle = True .Chart.Axes(xlValue, xlPrimary).AxisTitle.Characters.Text = "Spænding" 'Font størrelse og tal format .Chart.Axes(xlValue).TickLabels.NumberFormat = "0" .Chart.Axes(xlValue).TickLabels.Font.Size = 12 'Data linje tykkelse .Chart.SeriesCollection(1).format.Line.Weight = 1 'Fjerner data label .Chart.HasLegend = False 'Indsætter overskrift med logging interval. Start tid+dato - slut tid+dato .Chart.HasTitle = True .Chart.ChartTitle.Text = IIf([a2].Text < "", [a2].Text, [a2].End(xlDown).Text) & _ " - " & Cells(Rows.Count, "A").End(xlUp).Text End With End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Line chart- exact intervals | Charts and Charting in Excel | |||
How do I do a chart with overlaying confidence intervals? | Charts and Charting in Excel | |||
Chart Displaying Dates and Intervals. | Charts and Charting in Excel | |||
need to make chart w/ confidence intervals and don't know how | Charts and Charting in Excel | |||
need to make chart w/ confidence intervals and don't know how | Charts and Charting in Excel |