Excel scatter plot with multiple series. html>rn
Jun 27, 2023 · Step 3: Insert the Scatterplot. Select the range A1:C7, go to Insert > Chart, switch to "Chart types" tab and pick Scatter. Go to the Insert tab and click on the Scatter plot icon. Set Chart1 = Charts. We may frequently need to combine numerous data series into a scatter plot. Select the labels, Right-click on them and choose "Format Data Labels" from the dropdown menu. Scatter plots are used to check the correlation between variables, or the trend of the values. The result: two series with independent X values. Jun 6, 2019 · While you initially created a series and assigned it values, you've neglected to create a new one for your second series. Name the template and click Save. . Click OK: Once you have specified the data Nov 22, 2010 · 25. If you want the points connected by lines, you need to get them into the same series. From the Create Table dialog box, press OK. (for many, many rows) May 6, 2014 · So it'll find which row the series named "A" has its first entry, the one you labeled A1, and then in column C it'll look up the X value, and in column D it'll look up the Y value. Mr. one line is filtered to females, the second is filtered to Caucasians). On the Chart Design tab of the ribbon, in the Data group, click Select Data. Dec 28, 2014 · To plot what you are looking for, enter each dataset as a separate data series. Select the table. Click Add above the bottom-left window to add a new series. Click OK. A potential pitfall: if on the "Recommendations Straight Lines. The Insert Chart dialog box will appear. I am doing a scatter plot. I want to show each name seperatly on the scatter plot. Do something similar for the y-axis. Add a comment. Dim MyCht As Shape. Then right-click the chart and choose Save as Template. This plot will look like. Series. Add. Insert a scatter plot: Go to the "Insert" tab and click on "Scatter" in the Charts group. Type the new series label in the Series name: textbox, then click OK. In the Charts group, click on the Scatter icon, and choose the first Select the cells in the formula columns (cells D2:E15) and create the chart using Insert / Scatter Plot on the Ribbon. Note: also see the subtype Scatter with Smooth Lines. For this reason I cannot just select one large range for x & y and call it a day because I need individual series names. Code for two such functions are shown below. plot (df[' C ']) #display plot plt. g. Press Ctrl + D to duplicate the plotted graph. Mar 31, 2021 · Context: I created a chart with two lines in Power BI that plots time-to-degree as a function of a test score; each line corresponds to a measurement based on a unique set of filters. Select the columns that have the data (excluding column A) Click the Insert option. Under Chart Tools, on the Design tab, in the Chart Styles group, click the chart style that you want to use. xlsxIn this video, I demonstrate how to create an Jan 17, 2013 · I need to create a scatter plot with multiple series name:for example: a 1 4 b 3 5 c 6 7 d 3 5 e 4 6 f 5 6 I want the series name to be the first column, X axis Second Column, Y axis Third column. Enter the values 0. Go to the Insert tab in the ribbon. Create bins in another column (Excel will do this automatically but you need to be sure both series have the same bins) Go to Data|Data Analysis|Histogram. Dim Chart1 As Chart. Select Paste Special Select Add. Choose the scatter plot option that best fits your data. Download the featured file here https://www. Dot plot charts also employ the features of scatter charts. y-axis = the number of daily transactions, between the above interval, for 1000 stores. Under “Charts,” select “Scatter. This is the type Scatter with Straight Lines and Markers, or in VBA xlXYScatterLines. Use this option to check for linear relationships between variables. Select the series you want to edit, then click Edit to open the Edit Series dialog box. For this Select Data > Insert > Charts > Scatter > Scatter chart with line. Click on Insert Scatter (X, Y) or Bubble Chart. In a scatter chart, you can adjust the independent scales of the axes to reveal more information about the grouped values. I would like to select the series column and then plot the following: d vs. Click the ‘Align Center’ option. Click in the 'Chart data range' box. The graph shows a cross-sectional of the stream where the black is the stream bed shape, and the blue line marks the water level in the stream bed. Name the series. backend. Set the number format to Number, with 1 decimal place. This video explains about How to add multiple trendlines in a scatter plot in Excel. Select the chart, choose Paste Special from the Paste dropdown on the Home tab, and choose these options: New Series, Values in Columns, Series Names in First Row, X Values in First Column. Assuming your data starts in cell A1 and ends in cell G4 without any gaps, if you select A1 and then insert a new Scatter Chart, Excel will create the chart you desire. 2. Series 2 Data Data. Steps: Choose the data. Format them all to the marker color and size you want. assists will automatically be created: Next, perform the following steps: Click on the values on the x-axis and change the minimum axis bound to 80. To implement this, just select the range of the two variables. plot (df[' A ']) plt. With the dummy data, the chart looks like this when just inserted: Now some formatting changes have to be made to the chart. Navigate to the “Insert” tab Apr 25, 2022 · Step 2: Create the Scatterplots. This would bring a small text box to the top of your chart. Add the new series: Go to the "Design" tab on the Excel ribbon, click on "Select Data", and then click "Add" to add a new series. 5 and 3. In the Edit Series window, click in the first box, then click the header for column D. May 13, 2009 · I have a multiple columns representing Y values each against a specific x value. Arrange data in separate junks like in the example below. , C5:C9 for X and D5:D9 for Y). Click the lower part of the Paste button on the Home tab of the ribbon. But if you are worried about the spread of data in set 1 and set 2, and difficulty in pattern understanding, you can switch x & y and you can use secondary axis. In the Chart group, click on the Insert Scatter Chart icon. Scatter Plot with rows as individual series. We cover scatter plots with one data series and with multiple series, and talk about how to add essential context like trendlines, quadrants, and data labels, and how to customize each of these to your preferences. Next, let’s highlight the cell range A2:B9, then click the Insert tab, then click the Scatter button within the Charts group. On the Insert tab, in the Charts group, click the arrow next to Scatter Charts. Jun 18, 2019 · Plot multiple time-series data with different date/time in Excel. 6257. Right-click on the data series and choose "Add Data Labels" from the dropdown menu. Select one of those. 0. Right-click on chart, choose 'Select Data'. 'Set aRng = Selection. Option 1: Select the two continuous variables. For example: size weight. Move on to the Insert tab and select Insert → Charts → 2-D Column → Clustered Column. Add a 6th series. Use the pop-up dialog to specify the three ranges for the label, the X and the Y values. Then click Data Labels, then click More Options…. In this case, it’s G4:G14. The scatter plot node configuration only permits 2 choices under Jun 15, 2024 · Go to the Insert tab. Right-click on a data series and select Add Trendline. Select the bubble with the 3-D effect icon. From the chart options, select any chart suitable for your data. Secondary horizontal axis in MS Excel scatter Nov 19, 2014 · Remove the column labels from the X data columns. ) operator. Once you’ve selected your data, click on the “Insert” tab at the top of the screen. After producing this kind of scatter plot, the following step is to add labels to the chart to make it easier to interpret. Jun 5, 2016 · According the MS Specification you can apparently have a maximum of 255 series. Jan 30, 2023 · Select the Data Series in the chart. Excel will automatically generate a scatter plot based on your data. Plot a best fit line4. Once highlighted, go to the "Insert" tab and then click the "Insert Scatter (X, Y) or Bubble Chart" in the "Charts" group. Apply a multiple of the standard deviation, using the following Oct 12, 2017 · Excel expects the data series to be organized in columns. Select the scatter plot design that you want to use, such as “Scatter with Straight Lines and Markers”. Jan 15, 2024 · While a scatter chart uses two axes, a bubble chart can support three data series where each series has different sets of values. Jun 27, 2023 · Click on the “Insert” tab on the top of the screen. Step 3: Format Data Series. Provide a few cells where the user can select a few series names. We opted for the Line with Markers chart. Select the appropriate X and Y values (e. Add series. For statistical analysis, select the Display R-squared value on chart option to show the strength of the May 22, 2017 · Plot all data in the chart, format all series gray. Scatter Plot can be easily generated in excel using single Feb 5, 2018 · There's one graph that is used to visualize the "base flow" of the stream. Here's my code so far (without the dynamic series part ofc) Sub creatingmyscatterplot() 'Dim aRng As Range. Insert a default XYScatter plot. m = number of series for point y in chart n = number of points in each series y is = data value of series s and the I th point n y = total number of data values in all series. Add data labels. Oct 2, 2018 · If you do not want to add the columns you can do the following: Once you have your base chart without the horizontal lines, right click the chart and click 'Select Data'. But later on you may want to put a second set of data or a second line into your Mar 15, 2016 · Select the plot; Goto "Design" tab and "Select Data" "Add" the new series and select data points in new series; And it will look like. This video will show you step-by-step how to create informative and visually appealing scatter plots with multiple data series in Excel. The dataset will be converted into a table. Here, select the scatter plot style you'd Take your data analysis skills to the next level with our latest tutorial from the Data to Decisions” series!Learn how to create a scatter plot with multiple If you expect to need this for many different chart what you can do is create a template with as many series as you will ever need. Then create a series A on your graph with X coordinates from column C and Y coordinates from column D, and as your underlining data gets more rows or rows change Jun 18, 2014 · Step by step. pyplot as plt #plot each series plt. In this step, we will insert the graph for the above dataset. In the first, the cells will be blank or will have an "x" to indicate high liability. Standard Deviation. Plot your four data series on a basic column chart. A scatter plot, which is also called scatterplot, scatter graph, scatter chart, scatter diagram, is a type of plot that uses Cartesian Coordinates to display data for two variables of a set of data. Mar 9, 2023 · Add trendlines to your scatter plot to highlight the relationship between variables. Use formulas to populate helper cells with the corresponding values of that series. Select a X/Y column pair in the source data and copy. Select col 1 as the Y values, col 2 as the X values. Click the drop-down for Insert Scatter (X, Y or Bubble Chart icon under Charts group. Or, highlight the three Y columns to get the process started and then edit each data series to add the X values. 625, 2. Sample Data: Oct 6, 2022 · Step 3: Add the Second Data Set. The filters can have overlapping data (ex. Then, all the selected charts will align the center as below. Click on Add to add series data. Then, click “OK” to confirm the changes. Right click the data area of the plot and select Select Data Click the Add button to add a series. Your scatter plot should now appear on the screen, showing the data you selected. Plot a scatter plot3. #. enter = {1,20} in the Series X values field - this is the start and end values for the x range. To create a scatter plot with straight lines, execute the following steps. By default, matplotlib is used. Jan 17, 2023 · Along the top ribbon, click the Insert tab and then click Insert Scatter (X, Y) within the Charts group to produce the following scatterplot: The (X, Y) coordinates for each group are shown, with each group possessing a unique color. Stop the macro and then go look at the code. After selecting the one of the above methods, the data adds to table successfully. Click the chart area of the chart. d vs Price. Step 1: In the “Select Data Source” window that appears, click on the “Add” button under the “Legend Entries (Series)” section. May 26, 2011 · You can use the lower level plotting function points() to add points to an already existing plot. 5. Next, let’s add a legend and some axes labels to make the plot easier to To edit the series labels, follow these steps: Click Select Data button on the Design tab to open the Select Data Source dialog box. By the way, since you're using a With/End With statement to refer to your chart, you can start your lines with the dot (. For example, right-click the x-axis (numbers 0 to 4), click Format Axis, and change Minimum and Maximum by clicking Fixed (instead of Auto) and filling in the values that you want, perhaps 1. Feb 2, 2022 · In this post, we cover the basics of creating a scatter plot in Excel. Make plots of Series or DataFrame. A dialog box will show up. To update the chart each month, either paste new values on Watch in this video How to add Trendline in Excel for Multiple Series and find the equation of a trendline and R2 (linear regression values in Microsoft Exce This help content & information General Help Center experience. If I had this data I would want the result to be a scatter plot graph with all the apples in one series, all of the oranges in their own series etc with Oct 6, 2017 · Any help with explanation is greatly appreciated :D. Add a helper column to your data. Click the My Apps button to access the ChartExpo add-in. ), how can I get a scatter plot that looks like this? Sep 8, 2015 · Since there is only one point per series, each series in the chart has a single data point, and no lines to connect to other points. Search. Right-click the chart and choose Select Data. . Select Regression from A nalysis Tools and click OK. Next, let’s plot the sales of each company on the same chart: import matplotlib. I would copy these functions into your Excel file, apply them to the identical points and draw an (xy) scatter chart of the jittered data. Dim names2 As String. To separate them, right-click on any line and select the Format Data Series option. – davidmneedham. This video shows how to:1. Step 2: In the “Edit Series” window, specify the range for the X and Y values of the additional data set that you want to add to the scatter plot. etc. Hello, I am trying to create a scatter plot in Excel07 using VBA. (for many, many rows) I'd like to select the whole set of data and plot an xy chart identifying that the data is in rows and the first column contains the series name. min = 0. However, the way each of these chart types plots data along the horizontal axis (also known as the x-axis) and the vertical axis (also known as the y-axis) is very different. Sep 2, 2021 · Step 3: Add Labels to Points. Option 1: Plot both variables in X vs Y scatter plot style. Jun 23, 2023 · Click on the “Insert” tab in the Excel ribbon, and select the “Scatter” chart type. Jan 29, 2024 · Step 2: Insert a Scatter Plot. Make sure to include the column headers if you have them. Choose a Series name. Apr 8, 2021 · Step 2: Plot Multiple Series. Click inside the box below Series X values, then select the X data (either click and drag or Nov 18, 2015 · 2. Choose the type of trendline that best fits your data, such as linear, exponential, or polynomial. View solution in original post. Inserting a chart with multiple data sets. On the Insert tab, in the Charts group, click the Scatter symbol. The data will be pulled from the other series where there is an index value. Insert a scatter chart. In the Format Data Labels window that appears on the right of the screen, uncheck the box next to Y Value and check the box next to Value From Cells. Click on the graph to select it, and choose Source Data from the Chart menu. If this doesn't work, press Ctrl+Z to undo the change. Sub FormatSeriesTheSame() If ActiveChart Is Nothing Then. Excel 365, Windows 10. You can enter X and Y columns to create the first series, then add each remaining series. Once your data is set up, you can easily create a scatter plot in Excel. Now you will have the chart window as shown below. 3. From the Charts section, select Line or Area Chart. Go to the Insert tab and select Table. , rows) and the dates at which they occur aren't at uniform intervals in the table. plot (df[' B ']) plt. Jul 9, 2018 · Option Explicit. Leaving the dialog box open, click in the worksheet, and then click and drag to select all the data you want to use for the chart, including the new data series. An engineer might be interested in seeing a scatter-plot with row 1 data as series 1 and row 58 data as series 2. A blank chart will be created. Highlight data. Without altering the worksheet at all (no additional columns, rows, etc. Click the ‘Align’ icon in the ‘Arrange’ group again. Uses the backend specified by the option plotting. When plotting each series, I can easily select the y values as they are present in columns but the x value is constant for each column and I cant seem to figure out how to repeat a constant x value against several y column values. Under "Label Contains", check the "Value From Cells" box and choose the range with the desired labels (in this case A2:A5) Final Mar 18, 2021 · Do the following: Select the values in the second column. Then type “Team B” for the Series Name, then choose D3:D12 for the Series X Values and E3:E12 for the Series Y Values: Once you click OK, the Mar 11, 2020 · For the chart, the remedy is to modify the format. Click on it, and Excel will insert a basic scatter Oct 31, 2013 · 4. Here is how it looks like with my example: Here is how it looks like with my example: Once this is done You can change the color or the position of a dot instantly, in Excel, by changing the values in the spreadsheet. Series 3 Data Data. Nov 9, 2011. When you are ready to make your next chart, choose Insert, Scatter Mar 21, 2021 · In this video, you will learn how to make Scatter Plot for Multiple Data Sets in Microsoft excel. Oct 27, 2022 · To create a scatter plot, open your Excel spreadsheet that contains the two data sets, and then highlight the data you want to add to the scatter plot. #1. The object for which the method is called. Scatter charts and line charts look very similar, especially when a scatter chart is displayed with connecting lines. Clear search Mar 27, 2017 · However, a combination chart can do it quite easily. Perfect for comparing trends, identifying May 21, 2020 · If you're creating a scatter plot it may begin with one series of x,y data. From here, select the scatter plot that best fits your data. Select an empty cell. bluepecantraining. Once we click on Scatter Line Curve, excel will automatically insert graphs for multiple series according to our dataset. B. Format your secondary horizontal axis as. Hope you wanted either Mar 30, 2005 · Series 1 Data Data Series 2 Data Data Series 3 Data Data etc. Feb 22, 2023 · Step 2: Inserting Chart With Multiple Data Sets. Then, hold Ctrl and highlight every cell in the range D2:F9. Select the chart and use Paste Special. Add 2 additional helper columns to each series. They don't have the same number of entries (i. Switch the data rows and columns – Sometimes a Add multiple data series to a graph. max = 8. 625. Specify the data range: In the "Edit Series" dialog box, specify the x-values and y-values for the new series by selecting the appropriate range of cells in your worksheet. The following scatterplot of points vs. In this tutorial, you will learn how to create a scatterplot with multiple series in Excel. Mar 2, 2024 · To insert a scatter plot with multiple data series in Excel, select all the columns of your data, and go to the Insert tab. Excel makes some awful mess of this - misplotting data against some summed x-axis. ' axccording to your code, you are using "Sheet3" , fully qualify all your Ranges and Cells. Click the ‘Align’ icon in the ‘Arrange’ group. IF You have your data layed out as suggested, record a macro of you making the first graph with the first series. Copy it. 625, 1. Click on “Scatter” on the “Charts” section. Blobby said: I have data that looks like this: Label X-value Y-value. My desire is to both "color-in" the stream bed below the black line, and the water between the blue and black lines. Repeat for the '1'. Next, highlight the range A2:A9. I need to plot multiple series from one table, all of the series on the same graph. By default, Excel will create a chart with markers and lines; however, you can choose to display only markers. Apr 30, 2024 · Method 3 – Plotting a Graph in Excel with Three Y-Axes. Set the options as in the screen shot, i. plot. Select the type of scatter plot you want to create. Go to the ribbon. Optionally, format the x-axis to have a major unit of 1. BUT Excel has a shortcut to remedy this problem. This displays the Chart Tools. Dec 24, 2013 · Re: Scatter plot with multiple series from 1 table In order to create a combination chart, I need to reorganize my data so that each column is one group. show () Step 3: Add a Legend and Labels. Torque vs Price. It works in exactly the same way you create a scatter plot through plot() except that it adds points to the currently used plot. Select the range A1:D22. Sub PlotMultiSeries() Dim i As Long. It usually looks like a bunch of dots scattered around, hence the name. You can choose your preferred one from here. Click Scatter with Straight Lines. Apr 4, 2018 · Split your data into columns (one for your '0' points and one for '1') points. In the X Y (Scatter) tab, you will find two presentation styles for each chart type. Next, click anywhere on the chart until a green plus (+) sign appears in the top right corner. The lines don't go across the gaps in the table (first chart), so right click on the chart, choose Select Data, , click on the hidden and empty cells button at the bottom left of Insert - Chart - XY Chart w/ no lines. In this section: Microsoft Excel Tutorial: How To Put Multiple Data Sets On A Scatter Plot In ExcelWelcome to MrExcel Episode 1991, where we will be discussing the 2-Series S Right-click the chart, and then choose Select Data. Then click the Insert tab along the top ribbon and then click Insert Scatter (X, Y) within the Charts group: The following scatterplot will appear: Each of the (X, Y) coordinates from the dataset are shown on the May 20, 2023 · Step 3: Insert Your Chart. Your data table should really have the x-axis values (Months) in the first column, and the y-axis values for each data series in subsequent columns. After selecting your data, click the Insert tab at the top of Excel. May 11, 2020 · In "Chart Before" I have formatted the original series with a black line and the first iteration with a gray line. Add multiple data series to a graph. Steps: From the Data tab >> select Data Analysis. Series 1 Data Data. Right-click on the blank chart and select Select Data. Excel Scatter Plot Multiple Series. Select your '0' points and the bins, then put the output on a 'new worksheet ply'. Option 2 involves plotting the variables separately in two different series. CurrentRegion. You don't need any tricks to do this: just use the data in the natural way. Jul 16, 2018 · 101 4. 1. Only used if data is a DataFrame. Apply a percentage of the value for each data point in the data series. Go into the data labels formatting and check the "value from cells" circle. The above steps would insert a scatter plot as shown below in the worksheet. Steps: Select the complete dataset. Click on the ‘Scatter chart’ option in the charts thats show up. From the list of Chart elements that open up, check the box for ‘Chart Title’. Add a data series and use the dates for the x values and the times for the y values. MsgBox "Select a chart and try again!", vbExclamation. Select the range containing both the series names and the series values. Allows plotting of one column versus another. For example, you can choose “Scatter with Only Markers” or “Scatter with Smooth Lines and Markers. Under the Insert option, select the Scatter chart with lines option. Select More Scatter Charts. The scatterplot has multiple points, and I want the series name to be displayed as data labels on each of the points. com/wp-content/uploads/2021/05/Scatter-Graph. ”. Choose either Bubble or 3-D Bubble. Create an XY chart. tick "Series Names in Firstrow" and "Categories in Fist column". And when you edit the data (where you created a scatter chart Jan 8, 2015 · 1. Here's what I get: (If the data is arranged as you have it, with separate rows for separate series, it still works the same). The second will have a count of all x's above to give an index of high liability cases. For example: plot(1:10) points(10:1,col="red") Edit: One way to do the colors is by using rgb() as Chi suggested. Jul 16, 2018 at 16:00. The screenshots show this in action with a line chart Select and copy the second data set. "Chart After" is the result of a simple VBA procedure, below the screenshot. Mar 30, 2005 · Finally, double-click the series, from the Patterns tab set Line to 'None' and from the Options tab select 'Vary colors by point'. Label your axes: Right-click on the chart and select "Add Chart Element" > "Axis Titles" to add titles to the X and Y axes. Select the range of dependent variables (Input Y Range). I don't know exactly how to phrase this but I am essentially hoping to group data into series for an excel plot based on a column value preceding the other data. Related Videos:----- To select all the charts, I have to hold the Control key and click on each graph. pandas. 'Dim seriescheck As Range. Plot the helper cells as additional series in the chart and format them with colors. One way is shown below. As you can see, all lines clotted in one place in the final step. Then look for “Scatter Plot” in the list of charts, as shown below. Under 'Legend Entries (Series)' select the 'Add' button. So when I add new data to the table I don't have to reselect all the series for the appropriate graphs. Dim Ser As Series. Input data labels: Click on the data points in the scatter plot and select Dec 16, 2018 · Example below. Click on the chart> Chart filters> select data> Edit> in the edit series select the range in the both X and Y series and press ok. fi you can see what was done record the same process this time add a second series after the first. By default, Excel will use a different marker symbol for each After I've created my scatter chart I can upload it in Excel by pasting the URL in the funfun Excel add-in. I find that a lot of charting questions are really about how to rearrange the data in the spreadsheet. e. Use the average function in excel2. Jul 6, 2024 · Step 2 – Create the Multiple Regression Analysis in Excel. The most useful way to analyze this data would be multiple series in a scatter plot in Excel. The Select Data Source dialog box appears on the worksheet that contains the source data for the chart. Inserting a scatter plot in Excel. Once the ChartExpo is loaded, you will see a list of charts. If you arrange your pivot table as shown below, with dates in the row area and names in the columns area, the pivot chart will show distinct lines for each name. Click on the Chart Elements button as shown above. A drop-down menu will appear. Jun 29, 2024 · Go to the Insert tab in Excel. That might lead to wanting to see a plot of row 8 and row 97. Choose the first scatter plot option (the one with data points not connected by lines). Dim names3 As String. Highlight the cells containing the data you want to include in your scatter plot. You can then select the cells with the labels you want on the chart. Then click Select Data from the dropdown menu: In the new window that appears, click Add under the Legend Entries box. Next, right click anywhere on the scatter plot. Note: For information about the different types of Jun 10, 2021 · Hello, Is it possible to create a scatter plot comprising multiple series (1000 for example) with increased interactivity (in the view pane to be able to select a series by click-in points). Then, look for the Charts group and find the Scatter plot icon. I To get started with ChartExpo, follow the simple steps below. Go to the ‘Shape Format’ tab. Oct 26, 2018 · By selecting the entire data> ctrl + Q> Charts> Select the Chart. Remove the legend. Select your data. Select ChartExpo add-in and click the Insert button. Change the chart type on your yellow and green series to XY/Scatter type. Jun 14, 2024 · Method 1 – Insert Table to Create Dynamic Chart with Multiple Series. Jitterx, jitters the x coordinate of one data point if it overlaps another and jittery jitters the y coordinate. This time, Excel won’t know the X values automatically. I'd like to get, for this table, an Excel chart with 3 data series lines, where X axis is a Apr 9, 2022 · Click anywhere in the chart. Jan 20, 2024 · Select the scatter plot by clicking anywhere on it to launch the three icons on the right of the plot. Torque. As you can see there are multiple series here: Income, Short-Term Capital Gain, and Long-Term Capital Gain. Percentage. Dim names1 As String. un pn rn mi ky nr jt wz cm ba