简体   繁体   中英

How to visualize lists as x-axis in Matplotlib?

Say I have two lists:

xlst = [[1,2,3],[2,3,5],[3,1,2],[2,5,3],[3,0,1]]
ylst = [0.25,0.22,0.35,0.37,0.17]

I have this kind of data because the lists in xlist are given by 3D coordinates. Now I want to train a machine learning model using xlst as features and ylst as labels. To visualize data, I need to plot xlst as x-axis and ylst as y-axis in a same graph using Matplotlib. How should I do it to make the graph comprehensible?

Say I have two lists:

xlst = [[1,2,3],[2,3,5],[3,1,2],[2,5,3],[3,0,1]]
ylst = [0.25,0.22,0.35,0.37,0.17]

I have this kind of data because the lists in xlist are given by 3D coordinates. Now I want to train a machine learning model using xlst as features and ylst as labels. To visualize data, I need to plot xlst as x-axis and ylst as y-axis in a same graph using Matplotlib. How should I do it to make the graph comprehensible?

Say I have two lists:

xlst = [[1,2,3],[2,3,5],[3,1,2],[2,5,3],[3,0,1]]
ylst = [0.25,0.22,0.35,0.37,0.17]

I have this kind of data because the lists in xlist are given by 3D coordinates. Now I want to train a machine learning model using xlst as features and ylst as labels. To visualize data, I need to plot xlst as x-axis and ylst as y-axis in a same graph using Matplotlib. How should I do it to make the graph comprehensible?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM