Answers for "rotate plot matplotlib 90 degrees"

1

rotate matrix 90 degrees clockwise python

#rotate 90 deg clockwise
box=[["a","b"],["c","d"],["e","f"]]

rows = len(box)
cols = len(box[0])

box2 = [[""] * rows for _ in range(cols)]

for x in range(rows):
    for y in range(cols):
        box2[y][rows - x - 1] = box[x][y]
Posted by: Guest on May-16-2021

Code answers related to "rotate plot matplotlib 90 degrees"

Python Answers by Framework

Browse Popular Code Answers by Language