Plot specific lines from different files











up vote
0
down vote

favorite












I have several files with content as show below.



iter,dev
0,9.92535
1,40.7503
2,40.684


I would like to draw the second row (the one with iter 1) from each file with x value as index of file and y value as dev. For example, if there are 3 files, x values will be 0, 1, 2 while y values will be dev from second row of each file. My first idea was to make a new file and gather all data with python and then plot with pgfplots but I would like to know if this is possible with pgfplots alone.










share|improve this question


















  • 1




    This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
    – Jeffrey J Weimer
    Nov 19 at 13:55















up vote
0
down vote

favorite












I have several files with content as show below.



iter,dev
0,9.92535
1,40.7503
2,40.684


I would like to draw the second row (the one with iter 1) from each file with x value as index of file and y value as dev. For example, if there are 3 files, x values will be 0, 1, 2 while y values will be dev from second row of each file. My first idea was to make a new file and gather all data with python and then plot with pgfplots but I would like to know if this is possible with pgfplots alone.










share|improve this question


















  • 1




    This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
    – Jeffrey J Weimer
    Nov 19 at 13:55













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I have several files with content as show below.



iter,dev
0,9.92535
1,40.7503
2,40.684


I would like to draw the second row (the one with iter 1) from each file with x value as index of file and y value as dev. For example, if there are 3 files, x values will be 0, 1, 2 while y values will be dev from second row of each file. My first idea was to make a new file and gather all data with python and then plot with pgfplots but I would like to know if this is possible with pgfplots alone.










share|improve this question













I have several files with content as show below.



iter,dev
0,9.92535
1,40.7503
2,40.684


I would like to draw the second row (the one with iter 1) from each file with x value as index of file and y value as dev. For example, if there are 3 files, x values will be 0, 1, 2 while y values will be dev from second row of each file. My first idea was to make a new file and gather all data with python and then plot with pgfplots but I would like to know if this is possible with pgfplots alone.







pgfplots






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 19 at 10:03









Shibli

20219




20219








  • 1




    This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
    – Jeffrey J Weimer
    Nov 19 at 13:55














  • 1




    This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
    – Jeffrey J Weimer
    Nov 19 at 13:55








1




1




This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
– Jeffrey J Weimer
Nov 19 at 13:55




This is unclear. Do you want to plot the column dev versus the column iter? Or do you want to plot dev0 from from file 1 ... N versus file number, then dev1 from file number 1 ... N versus file number, then ...? Please explain. In the meantime, look at the datatool package as a way to pull in CSV files to LaTeX. Also, python can be embedded in LaTeX with for example the python package.
– Jeffrey J Weimer
Nov 19 at 13:55















active

oldest

votes











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "85"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f460711%2fplot-specific-lines-from-different-files%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f460711%2fplot-specific-lines-from-different-files%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

How to change which sound is reproduced for terminal bell?

Title Spacing in Bjornstrup Chapter, Removing Chapter Number From Contents

Can I use Tabulator js library in my java Spring + Thymeleaf project?