Hi everyone,
i am using local data filter to select items of legend to compare them. in this i have rows which are treated as targets (which i want to keep them as black color and dashed fit line). so i do that manually after fitting the lines. now when i start using local data filter, color of target data points changed to blue and all red and blue fit lines changed to black as well. as you can see in that in bottom picture.
i started using data filter because i want to hide fit line as well as data points when you select a legend since lines are not dynamic only data is.
i also have pasted code for data table which will have this chart too, if any one want to see the problem.

after data filter

New Table( "Test",
Add Rows( 16 ),
New Script(
"Bivariate",
Bivariate(
Y(
),
X( :a ),
Automatic Recalc( 1 ),
Fit Where(
:c == "A",
Fit Orthogonal(
Fit X to Y,
{Line Color( "Medium Dark Red" ), Line Width( 2 )}
)
),
Fit Where(
:c == "B",
Fit Orthogonal(
Fit X to Y,
{Line Color( "Medium Dark Green" ), Line Width( 2 )}
)
),
Fit Where(
:c == "tgt",
Fit Orthogonal(
Fit X to Y,
{Line Color( "Black" ), Line Style( "Dashed" ), Line Width( 2 )}
)
),
SendToReport(
Dispatch(
{},
"1",
ScaleBox,
{Min( 0 ), Max( 9.23175965665236 ), Inc( 2 ), Minor Ticks( 0 ),
Label Row Nesting( 1 )}
),
Dispatch( {}, "2", ScaleBox, {Max( 14.1371428571429 )} ),
Dispatch(
{},
"Bivar Plot",
FrameBox,
{DispatchSeg( Line Seg( 1 ), {Line Width( 2 )} ),
DispatchSeg( Line Seg( 2 ), {Line Width( 2 )} ),
DispatchSeg(
Line Seg( 3 ),
{Line Style( "Dashed" ), Line Width( 2 )}
), Row Legend(
c,
Color( 1 ),
Color Theme( "JMP Dark" ),
Marker( 0 ),
Marker Theme( "" ),
Continuous Scale( 0 ),
Reverse Scale( 0 ),
Excluded Rows( 0 )
)}
)
)
)
),
New Column( "a",
Numeric,
"Continuous",
Format( "Best", 13 ),
Set Values( [1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8] )
),
New Column( "b",
Numeric,
"Continuous",
Format( "Best", 13 ),
Set Values( [2, 3, 5, 6, 6, 7, 9, 10, 4, 5, 6, 7, 8, 9, 10, 11] )
),
New Column( "c",
Character,
"Nominal",
Set Values(
{"A", "A", "B", "B", "A", "A", "B", "B", "tgt", "tgt", "tgt", "tgt",
"tgt", "tgt", "tgt", "tgt"}
)
),
Set Row States(
[4864, 4864, 5120, 5120, 4864, 4864, 5120, 5120, 5376, 5376, 5376, 5376,
5376, 5376, 5376, 5376]
)
)