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 8012207
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T19:15:34+00:00 2026-06-04T19:15:34+00:00

Lets say I have a data file with three columns. I want to be

  • 0

Lets say I have a data file with three columns. I want to be able to change the x-axis labels. After a little googling I found xticlabels() but the problem is that it only seems to take a column number as the argument. For ex- plotting with xticlabels(3) marks the labels with the third column.

I want to be able to put something like $1+$2 as the argument for this function i.e. the label should be a concatenation of column1 and column2.

How do I do this ?

  • 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-06-04T19:15:36+00:00Added an answer on June 4, 2026 at 7:15 pm

    You use awk…

    plot "<awk '{print $1,$2,$1 $2}' datafile" u 1:2:xticlabels(3) 
    

    Of course, this is a silly example because we’re concatenating 2 (numeric) fields to create the labels — It’s doubtful that is what you want, but it shows how to concatenate two fields (as strings) in awk and that’s really all you need.

    Alternatively, you can probably coax gnuplot to do this (untested) with some variant of the following:

    plot 'datafile' u 1:2:( xticlabels( stringcolumn(1).stringcolumn(2) ) )
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Lets say I have 2 columns in my data Grid: Column A: Selected, and
Lets say, I have the following text file: Listing 1: Endianess=little AddressModel=32 typedef struct{
I have a file, lets say bigfile, with tabular data of the following form,
Let's say I have a tab-delimited text file that contains data arranged in columns
Lets say I have data in two tables. In one I have Order ID
So lets say we have data that looks likes: drop table if exists views;
Lets say I have this code: public void MyMethod(string Data, List<string> InputData) { //I
Lets say i have vector of vectors vector< vector<int> > bigTable; vector<int> data; data.resize(2);
Kinda stuck here... I have an application with lets say 5000 rows of data
Let's say I have data string like this... one=1&two=2&three=3&four=4&two=2 I'm using php foreach to

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.