How to replicate picture?

Hiya,
I would like to replicate the following plot:
I have an n x n binary matrix, the ones indicate where the road should be and the 0s where nothing should be. Ignore the red dot.
Thanks!

13 Comments

imshow?
imshow(~YourData)
to get the 1s to show up dark.
Use edge detection. It will identify the road boundaries.
s z
s z on 21 Sep 2018
Thanks for answering my question but with imshow() I get a picture like this
I think the figure is created in another way
Is your concern that the background is showing up in white instead of in light gray ?
Read this link first, then tell us what "replicate" means to you. Like make copies of, like the repmat() function does? We really have no idea what you're thinking.
s z
s z on 21 Sep 2018
Edited: s z on 21 Sep 2018
Couldn't it be possible to create a 3d plot and then you look at it from above - but I don't know how to do this
... We still do not understand what you are asking for, so we cannot advise you if there is a way to do what you want.
There might be, but since we don't know what you want, we don't know what to tell you. We don't know if it's a display/visualization problem, a line detection or segmentation problem, a replication/copying/pasting problem or something else.
s z
s z on 21 Sep 2018
It is an ML problem. By using a recurrent ANN a game has to be solved. A game where there is a car (red dot) and you want to minimize the amount the car is not between the road (the two lines). So this picture above is just a snapshot of the game you would plot after each result to see the car moving
What is ML? Do you have coordinates of the road boundaries and of the red spot/car location?
s z
s z on 21 Sep 2018
Machine learning - I figured it out! if you use plot3() and with view(2) you can have this birds view - thanks for the thoughts!!
jonas
jonas on 21 Sep 2018
Edited: jonas on 21 Sep 2018
Wew, the problem became less clear by each reply. Anyway, happy it worked out for you :)

Sign in to comment.

Answers (0)

Categories

Find more on Graphics Performance in Help Center and File Exchange

Tags

Asked:

s z
on 21 Sep 2018

Edited:

on 21 Sep 2018

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!