I am looking for a line chart for 4 different inputs does someone has a code that is already written ? It would save me lot of work
Hello Walder, welcome to the forum.
You can find the built-in help for the dashboard chart in the right hand column of the editor screen, the tab is indicated by a book icon. Also at https://flows.nodered.org/node/node-red-dashboard
It says
Multiple series can be shown on the same chart by using a different
msg.topic
value on each input message.
So if you wanted internal temperature, external temperature and dewpoint on one chart you could set msg.topic to "Internal temperature", "External temperature" or "Dewpoint" accordingly. The chart would automatically draw 3 lines.
A search of the forum would save us volunteers a lot of duplicate work
Have a look then come back with questions and info on inputs etc.
Well that is exactly the problem - i have searched over an hour but the only thing i was finding were codes with randomizers. All I want to do is to connect 4 Values but all the time i am only getting 1 chart not four. So i did what Jbudd sayd
changed it with a switch node -msg.payload to msgpayload[1] so if you dont want to answer this then dont but if some could be so nice to show me the mistake i would be very grateful. And yes ihave already been watching some toturial videos but it is not possible for someone to know that fast everything in node red even if it seems simpel to you.
As @jbudd said, you just need to set different topics for each one. So in the three wires bringing in the payload values use change nodes to Set msg.topic to different strings. The actual value should be in msg.payload.
So in the wire bringing in temperature in msg.payload you could insert a change node configured as
And in the wire bringing in humidity in msg.payload you might have
Thank you very much that helped a lot
I apologise if I did not explain clearly enough. It is indeed frustrating when you are trying something new and don't know where to look for help.
It would be easier to give you good advice if we knew a bit more about your setup:
- What operating system do you have Node-red installed on?
- You say you have 4 inputs. What measurements do these values represent?
- Where does the data come from and how does it get into Node-red?
- Please use a debug node to show us one of these inputs. Set it to display the complete msg object not just msg.payload. Something like this
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.