Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 694927
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T02:54:25+00:00 2026-05-14T02:54:25+00:00

Currently I have a a text file with data at the first row is

  • 0

Currently I have a a text file with data at the first row is formatted as follow: time;wave height 1;wave height 2;……. I have column until wave height 19 and rows total 4000 rows.

Data in the first column is time in second. From 2nd column onwards, it is wave height elevation which is in meter.

I would like to plot the follow:

on the x axis is time.
the left hand side is wave height in m
and on the right hand side is the distance between each measurment in a model.

inside the graph there are 4 plots, each plot is repersent waveight 1, wave height 2etc at a defined distance related to the right hand side y asix.

How would you code this in matlab?

I am a begineer, please if you could, it will be very useful to give a bit more explain in your answer! I was trying to post an picture up to clear things up but stackoverflow don’t allow me to do that. If it is un clear please contact me and i can email you the graph i mean for this question.

Thank you!!!!!!!!!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T02:54:25+00:00Added an answer on May 14, 2026 at 2:54 am

    What do you mean the “distance between each measurment in a model” when talking about the y-scale on the right?

    Given some data that looks like this:

    #Time               #Wave Height         #Distance Between Measurements(?)
     0000                1.00                 1.00
     0001                1.13                 0.81
     0003                1.58                 0.73
     ...                 ...                  ...
     4000                0.23                 1.19
    

    Where a vector containing all elements of the Time column is named times, the vector with wave height is called waveHeights, and the vector with distances is called distances you could use plotyy() in this way:

    [AX,H1,H2] = plotyy(times,waveHeights,times,distances,'plot');
    
    set(get(AX(1),'Ylabel'),'String','Wave Height') 
    set(get(AX(2),'Ylabel'),'String','Distance Between Measurements')
    xlabel('Time (s)')
    

    The first line is the actual plots and the last three add labels to the axes.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an XML file that looks like this <comments> <text> <![CDATA[ <!--cached-Tue, 02
Is there a way to read a file's data but continue reading the data
I have PDF documents containing several images/pages of scanned documents. Their (OCR-produced) text content
Let's say we have two files. match.txt : A file containing patterns to match:
Decided to try and learn Perl, and currently need to process a number of
I need to index around 10GB of data. Each of my documents is pretty
I have an embedded device which runs Java applications which can among other things
Okay, I'm having some serious issues here. I'm new to this site, and new
UPDATE : Once I looked at the problem in Firebug, I found my mistake
The class project has us reading in the title, artist and lyrics of 10,514

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.