Q:

xlsxwriter: modifying parts of a line in a scatter chart

in the Python package xlsxwriter, is it possible to format a part of a scatter chart series differently than another part? for example, a scatter chart where some sections of the line of a specific series are blue, and other sections of the same line are red. it is certainly possible in Excel itself by modifying specific data points.
I tried using the 'points' option in many combinations without success. I don't know which options are valid for it in a scatter chart. 
UPDATE:
here is an example of what I'm trying to achieve. This was created directly in Excel, not through xlsxwriter. Notice how one section of the line is dashed and red, and another is a different thickness. To create it, simply select a data point and use the options in the sidebar to adjust formatting.

A:

I've made an example that I think answers your question.
I'm using Python 3.5 and xlsxwriter 0.9.6.  
In chart 1, I changed the color of the markers based on whether they were in a particular group.  It's fairly straightforward if chart 1 is what you're looking for.
In chart 2, I show how to hard code a continuous line with different colors (there may be a better way to do this).  
import xlsxwriter
import numpy as np
import pandas as pd

dates = pd.DataFrame({'excel_date':pd.date_range('1/1/2016', periods=12, freq='M')})
dates.excel_date = dates.excel_date - pd.datetime(1899, 12, 31)
data = np.array([11,20,25,35,40,48,44,31,25,38,49,60])
selection = np.array([4,5,6,8,11])

#Creating a list - you could hard code these lines if you prefer depending on the size of your series
diff_color_list = list()
for n in range(1, 13):
    if n in selection:
        diff_color_list.append({'fill':{'color': 'blue', 'width': 3.25}},)
    else: 
        diff_color_list.append({'fill':{'color': 'red', 'width': 3.25}},)

#Workbook Creation
workbook = xlsxwriter.Workbook("test.xlsx")
format = workbook.add_format({'num_format':'mmm-yy'})
worksheet1 = workbook.add_worksheet("testsheet")
worksheet1.write('A1', 'Date')
worksheet1.write('B1', 'Data')
worksheet1.write_column('A2', dates.excel_date, format)
worksheet1.write_column('B2', data)

chart1 = workbook.add_chart({'type': 'scatter'})

# Configure the series.
chart1.add_series({'categories': '=testsheet!$A$2:$A$13',
                   'values': '=testsheet!$B$2:$B$13',
                   'points': diff_color_list
})

chart1.set_title ({'name': 'Results'})
chart1.set_x_axis({'name': 'Date'})
chart1.set_y_axis({'name': 'Data'})
chart1.set_legend({'none': True})

# Second chart with alternating line colors
chart2 = workbook.add_chart({'type': 'scatter',
                             'subtype': 'straight'})

chart2.add_series({'categories': '=testsheet!$A$2:$A$3',
                   'values': '=testsheet!$B$2:$B$3',
                   'line':{'color': 'blue'}
})

chart2.add_series({'categories': '=testsheet!$A$3:$A$4',
                   'values': '=testsheet!$B$3:$B$4',
                   'line':{'color': 'red'}
})

chart2.add_series({'categories': '=testsheet!$A$4:$A$5',
                   'values': '=testsheet!$B$4:$B$5',
                   'line':{'color': 'blue'}
})

chart2.set_title ({'name': 'Results'})
chart2.set_x_axis({'name': 'Date'})
chart2.set_y_axis({'name': 'Data'})
chart2.set_legend({'none': True})

worksheet1.insert_chart('D6', chart1)
worksheet1.insert_chart('L6', chart2)

workbook.close()

