Cody

Solution 875391

Submitted on 16 Apr 2016 by Rathin Joshi
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
x = rand(10,1); y = rand(1,10); colors = ['g', 'r', 'b']; colorNum = randi(length(colors)); color = colors(colorNum); colorCodes = {[0 1 0], [1 0 0], [0 0 1]}; color_correct = colorCodes{colorNum}; h = makeAPlot(x,y,color); poltHandle = get(h); plotColor = poltHandle(1).Color; plotX = poltHandle(1).XData; plotY = poltHandle(1).YData; assert(isequal(plotColor,color_correct)) assert(isequal(plotX',x)) assert(isequal(plotY,y))

h = Line with properties: Color: [0 0 1] LineStyle: '-' LineWidth: 0.5000 Marker: 'none' MarkerSize: 6 MarkerFaceColor: 'none' XData: [0.1716 0.4730 0.2998 0.8353 0.8009 0.9107 0.2321 0.3995 0.6316 0.3635] YData: [0.6857 0.2076 0.3388 0.2731 0.1893 0.5606 0.2046 0.6594 0.0085 0.0109] ZData: [1x0 double] Show all properties

Cpkhjsx7pa+rnv+onhb0q0fshoagnuaaga1aabydqaavgmagnuaakwgaacraqdaagaasboaakwgaga1aabydqaavgmagnuaakwgaacraqdaagaasboaakwgaga1aabydqaavgmagnuaakwgaacraqdaagaasboaakwgaga1aabydqaavgma4kp4p29ai6b9k8jiaaaaaelftksuqmcc"}]