Drawing on a Chart
I am using VBA in Excel to model some alignment errors in a test fixture.
The output is a multiple series scatter chart of the data. If I calculate the center and radius of a circle that fits a part of the data (least squares fit method), how can I draw the circle on a chart? Ron H. ----------------- www.Newsgroup-Binaries.com - *Completion*Retention*Speed* Access your favorite newsgroups from home or on the road ----------------- |
Drawing on a Chart
Hi,
The simplest way is to use a series to draw the circle. Add an extra data series to the chart plotted as xy-scatter line no markers. You can calculate the circle using basic trig formula. Assume, X Center in cell D1 Y Center in cell E1 Radius in cell F1 Range G1:G360 Circle XY points in range G1:H360 G1: =$D$1+(COS(ROW()*(PI()/180))*$F$1) H1: =$E$1+(SIN(ROW()*(PI()/180))*$F$1) copy down for 360 rows. Cheers Andy -- Andy Pope, Microsoft MVP - Excel http://www.andypope.info "Ron H." wrote in message ... I am using VBA in Excel to model some alignment errors in a test fixture. The output is a multiple series scatter chart of the data. If I calculate the center and radius of a circle that fits a part of the data (least squares fit method), how can I draw the circle on a chart? Ron H. ----------------- www.Newsgroup-Binaries.com - *Completion*Retention*Speed* Access your favorite newsgroups from home or on the road ----------------- |
All times are GMT +1. The time now is 04:07 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com