예제 #1
0
def test_CircleCross() -> None:
    marker = CircleCross()
    check_marker_properties(marker)
    check_line_properties(marker)
    check_fill_properties(marker)
    check_hatch_properties(marker)
    check_properties_existence(marker, MARKER, LINE, FILL, HATCH, GLYPH, ["marker"])
예제 #2
0
def test_CircleCross():
    marker = CircleCross()
    yield check_marker, marker
    yield check_fill, marker
    yield check_line, marker
    yield check_props, marker, MARKER, FILL, LINE
예제 #3
0
markerSizeUnselect = 3
markerSizeSelect = 15
sizes = [markerSizeUnselect]*Fs.size
sizes[RLoc] = markerSizeSelect

''' callback data sources '''
attributes = ColumnDataSource(data=dict(off=[offset], sSize=[markerSizeSelect], uSize=[markerSizeUnselect],
                                        uScale=[unitScale]))
plot1Arrs = ColumnDataSource(data=dict(Rs=Rs, Fs=Fs, sizes=sizes))
plot2Arrs = ColumnDataSource(data=dict(det=detunings, As=As, detGHz=detGHz))

''' ************** create plot **************** '''
lineSelection = Line(line_color='black', line_width=1, line_alpha=1.0)
lineUnselection = Line(line_color='black', line_width=1, line_alpha=1.0)
circleSelection = CircleCross(fill_color='red', fill_alpha=0.3, line_color='red', line_alpha=0.5, line_width=1,
                              angle=45)
circleUnselection = CircleCross(fill_alpha=0.1, fill_color='blue', line_color=None)

p1 = figure(title='Finesse of etalon against reflectivity (red cross indicates current finesse value)',
            name = 'finesseScatter',
            plot_width=300, plot_height=400) # note widths different to holeBurning (change to 400,400 if display issues)
p1.xaxis.axis_label = "Overall reflectivity of etalon"
p1.yaxis.axis_label = "Coefficient of finesse"
r1=p1.circle_cross('Rs', 'Fs', source=plot1Arrs, line_color=None, fill_color='blue', size='sizes', fill_alpha=0.1)
r1.selection_glyph = circleSelection
r1.nonselection_glyph = circleUnselection

p2 = figure(x_range=(-deltaOMEGA_I*plotWidth*unitScale,deltaOMEGA_I*plotWidth*unitScale),
            #y_range=(0,1),
            title='Normalised Airy function of a Fabry-Perot etalon',
            plot_width=500, plot_height=400) # note widths different to holeBurning (change to 400,400 if display issues)
예제 #4
0
def test_CircleCross() -> None:
    marker = CircleCross()
    check_marker_properties(marker)
    check_fill_properties(marker)
    check_line_properties(marker)
    check_properties_existence(marker, MARKER, FILL, LINE, GLYPH)
예제 #5
0
def test_CircleCross():
    marker = CircleCross()
    yield check_marker_properties, marker
    yield check_fill_properties, marker
    yield check_line_properties, marker
    yield check_properties_existence, marker, MARKER, FILL, LINE, GLYPH
예제 #6
0
파일: glyphs.py 프로젝트: PhilWa/bokeh-1
           y="y",
           radius=screen(15),
           start_angle=0.6,
           end_angle=4.1,
           fill_color="#B3DE69")),
]

markers = [
    ("circle", Circle(x="x", y="y", radius=0.1, fill_color="#3288BD")),
    ("circle_x",
     CircleX(x="x", y="y", size="sizes", line_color="#DD1C77",
             fill_color=None)),
    ("circle_cross",
     CircleCross(x="x",
                 y="y",
                 size="sizes",
                 line_color="#FB8072",
                 fill_color=None,
                 line_width=2)),
    ("square", Square(x="x", y="y", size="sizes", fill_color="#74ADD1")),
    ("square_x",
     SquareX(x="x",
             y="y",
             size="sizes",
             line_color="#FDAE6B",
             fill_color=None,
             line_width=2)),
    ("square_cross",
     SquareCross(x="x",
                 y="y",
                 size="sizes",
                 line_color="#7FC97F",