Articles, Blog

How To Import A Picture in LaTeX | TeXMaker How-To’s

Alright so in this presentation I’m
going to show you how to import a picture into a Tex document. Right now
I’m using TeXMaker but the basic idea is the same no matter which compiler
you’re using. so this point basically I’ve got the most
basic TeX document that you could have. I’ve just got the “begin document” and “end document” and then a document class and just a little bit of text, “Hello, and welcome to my presentation” There’s nothing else going on right now.
Let’s say at the most basic level all I want to do
is throw a picture somewhere in this document. Then you just
have to use a special package And and that package is called graphicx. axe all in lower case letters that’s
going to allow me to import a picture into this document so let’s say I have a
graph I that I wanna throw and it’s just
hanging out in my downloads folder it’s this one called graph 1 right there
I want to throw that in my tech document well there’s just one problem: out right now this is just hanging out
in my downloads folder on my computer it’s nowhere even close to that text document that I
have saved and so when technique or goes to look for this file
I you can specify a path for where you want to look it is only
going to look in the folder where that tech document is located so what you
have to do with any picture that you want to
include I’m just gonna move this I’m gonna control X and then move this into the same folder where my tech document is located
because when I don’t include this picture its only going to look within the same
folder so I just be very careful on that because
that’s are the most common area that you’re gonna get is gonna try and compile and its not
gonna any idea where this picture is if it’s not located in that same
subdirectory there so just make sure it’s moved in the same
folder and we should be good so the next step up I’m just going to use
the command include graphics it put a little scale feature in there
so tells me you know if I wanted a full size half size that sort of thing about
one for full size and then here you just type in the name
exactly as it saved in the folder so here notice it says I graph 1 that’s what we’re going to
type in our tech document here’s forget include graphics scale graph one there we go go ahead idk pile and you can see it throws the
picture right into our document I’m but notice what it
here did something a little bit strange we get our text right here at the top we
should include graphics I am right after it but for some reason
this graphic is showing up higher than the text in our presentation
I we don’t necessarily like that we would
like to be able to tell exactly where we want this picture to go in order to
do that you’re going to need to include a couple more commands I’m first things first though let’s
scale this picture down at a little bit big was 2.5 for half size it’ll be a little clear
notice there when we scale that it moved the picture again so it’s
jumping all over and just kinda throwing it in our presentation where we want we
want to be able to tell that where we want to go so we’re gonna use another command here
going to be called I began figure because that’s what we’re
including where including the pictures were gonna put are include graphics I command in between again figure and and figure part if I’m gonna change
anything right now I am but he gives us more options to I modified however we like so I am to specify exactly where in your presentation this picture goes
there’s a couple different options that you can put at the end of
this begin figure command I’m you can put 18 and that will ports I that will put the
picture at the top of the page you can put a B in there that will put
the picture at the bottom of the page at the command we want to use right now
isn’t H and that’s going to say include this
graphic here and so you notice now got the text and
then put the graphic right here after the tax that’s what it’s going to
do so up now we’ve got our picture exactly where we want in our
tech document I the only problem is its I it’s all the
way to the left and I really think it would look better if it was centered so there’s another option in between are
begin figure and figure I we can include the command here are
centering and that is just going to you movie right into the center I so they really got it centered we’ve got
it exactly in here there’s a couple other options
you can you say we want to include a little caption
under the bottoms picture I then you can just go past the picture
and you can say caption and then type whatever you like
here and not say the you well ordering principal implies induction if you don’t know that you
should look it up it’s an interesting print are so there we go and it automatically
numbers are figure 4 since this figure 1 the well or in principle implies
induction so there’s a little caption and then who want to be in typing can
say wow that’s really interesting there we go in our paper just continues
from there so that’s the basic idea that’s the most
simple way to include I a picture in attack document if you’ve
got any questions I’m feel free to post them in the
comments I should be answering them and I will be posting some more I tech instructional videos later thanks


  1. Alejandro Paladio Author

    Hello, it's a nice video, very helpful, thanks!
    I have a question, how can I change the "Figure 1 Blah blah", to "Picture 1 Blah blah"?
    Thanks again

  2. Vahab Yousofzadeh Author

    Thanks for video, you can call your figs from a different folder. Please see,

  3. Giovanni Battilana Author

    Hi, I've got a question: if I have to import a picture in LaTeX, for example a mathematical graphic and I have to name with greek letters some elements of this picture, should I name them directly in the image before importing it in LaTeX or can I name them in LaTex after importing it? I ask you this question because LaTeX gives very simple commands for subscripts, but I don't know how can I use subscripts directly in the image out of LaTeX editor.

  4. Shivaprakash Gopinath Author

    if i create a new folder in the latex folder and save all image on it… can i use that directly without any change…

  5. Sid Ed Author

    I have one alignment issue with this, but otherwise it works great. For one, when I insert an image this way, for some reason it interrupts the preceding text and breaks it apart over the image. Then, when I use the "center" command and give the text some space, it forces the text to align to the left margin of the image rather than the original left margin of the document.

  6. HisashiAya Author

    hi. excellent explanation! what is the command if i want to put 4 figures at once. like 2 rows x 2 columns. thanks in advance!

  7. Elyne Gilles Author

    Great video thanks ! I do have a problem tho, texmaker also print the name of the image I use before the image itself. Not like a caption, but as it was part of the text before, and I don't know how to take it off. It also tells me that my image is not found, but it does show it on the pdf, but I have to ad the .jpg at the end of the name eventhough it's in the same file. Do you have any idea of what the problem is ? Thanks !


Leave a Comment

Your email address will not be published. Required fields are marked *