function [handle] = plotMotif(loc, compLoc, y, symbol, markerColor,promoterLen) plot([-promoterLen+1:0], ones(1,promoterLen)*y, '-k') hold on handle1=[]; handle2=[]; if length(loc)>0 handle1 = plot(-(promoterLen-loc),ones(1, length(loc))*y, symbol, 'MarkerFaceColor',markerColor, 'MarkerEdgeColor','k'); plot([-promoterLen+1:0], ones(1,promoterLen)*(y-0.25), ':k') end if length(compLoc)>0 handle2 = plot(-(promoterLen-compLoc), ones(1, length(compLoc))*(y-0.25), symbol, 'MarkerFaceColor',markerColor, 'MarkerEdgeColor','k'); plot(0, y, 's', 'MarkerFaceColor',[0.8 0.8 0.4], 'MarkerEdgeColor','k') end if length(handle1)>0 handle = handle1; else handle = handle2; end