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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:54:28+00:00 2026-06-15T23:54:28+00:00

I made a doubleYScale plot: library(lattice) library(latticeExtra) # Some data foo <- list(x =

  • 0

I made a doubleYScale plot:

library(lattice)
library(latticeExtra)

# Some data
foo <- list(x = 1:100, y = cumsum(rnorm(100)))

obj1 <- xyplot(y~ x, data=foo,xlab=list(cex=1.2), 
               main="TOtalProduktion VS SummaSkulder/TotaltKapital i procent",
               type = c("l","g"),col="black",
               lty=1,key = simpleKey(col=c('black'),
               text=c("Produktion"),cex=1.2,points=FALSE, lines=TRUE),
               scales=list(x=list(rot=90,tick.number=25,
               cex=1,axs="r")))

obj2 <- xyplot(y^2 ~ x,data= foo ,type = "o",col="black",
               lty=9,key = simpleKey(col=c('black'),
               text=c("Summa.skulder"),cex=1.2,lines=FALSE,points= TRUE))

doubleYScale(obj1, obj2, add.ylab2 = TRUE)

enter image description here

The problem is that I cant manage to change the text size of the y-axic labels (y and y^2 text, I want to make it larger). It is no problem to change it if I only plot obj1 or obj2 separately, but it doesn’t work for doubleYScale…

I can on the other hand change the size of numbers on the y-axices with:

trellis.par.set(axis.text=list(cex=1))

Any suggestions? I can’t manage to find a way 🙁

  • 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-15T23:54:29+00:00Added an answer on June 15, 2026 at 11:54 pm
        library(grid)
        ##  the text size of the 2 y-axic labels
        grid.edit(gPath='GRID.text',grep=T,global=T,gp =gpar(cex=3))
    

    If you want to set different axis sizes

        grobs <- sapply(grid.get(gPath='GRID.text',grep=T,global=T),'[')['name',]
        grid.edit(gPath=grobs[[1]],gp =gpar(cex=2))
        grid.edit(gPath=grobs[[2]],gp =gpar(cex=1.5))
    

    enter image description here

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

Sidebar

Related Questions

Made a custom obj called Item with some string fields and one float. .h
I made a Web service in which I have a function to count some
I made a tkinter window in python with some widgets like so: def createWidgets(self):
I made a custom styled list in WPF: <DataTemplate x:Key=SelectedTemplate> <StackPanel Background=#FF4E4E4E HorizontalAlignment=Stretch> <TextBlock
I made a function that overwrite the the :hover of some elements on a
I made a blog database and created some tables in it. I have wriTten
I made a project in Netbeans 6.8 and added a third-party library which included
I made an Excel file with data on tab 2, and a chart on
I made some changes to a project that I need to take out. The
I made a program in which I wanted to manually update the Data Grid

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.