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

  • SEARCH
  • Home
  • 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 3617914
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T22:41:06+00:00 2026-05-18T22:41:06+00:00

I have some data with some hard to deal with properties. There are two

  • 0

I have some data with some hard to deal with properties. There are two vectors that are taking a measure of quality (from 0-1) at points along a physical object. These measurements are indexed according to the distance the measurement was taken from the bottom of the object. Then, a quality improving transformation is applied to the object, and measurements are taken again. However, the number of measurements are not the same, nor are the points on which they are taken.

In R, the data looks something like this (but with many more points)

Before transformation:

     value index
[1,]   0.3     6
[2,]   0.6    16
[3,]   0.1    25
[4,]   0.8    37
[5,]   0.2    46
[6,]   0.4    58
[7,]   0.4    64
[8,]   0.2    76

After transformation:

      value index
 [1,]   0.3     1
 [2,]   0.5     9
 [3,]   0.7    18
 [4,]   0.4    30
 [5,]   0.9    44
 [6,]   0.3    48
 [7,]   0.4    61
 [8,]   0.5    66
 [9,]   0.3    76
[10,]   0.1    85

Under the assumption that quality along the object is continuous (if not observed at every point), and that the ammount of improvement during the tranformation is dependent on the point along the object, I would like to be able to show the distribution of quality improvement.

Since there are different numbers of measurements, and different indexes, I don’t think

plot(density(after$value - before$value)) 

is what I’m looking for. My question is, is there a sane way to take that difference such that I have a number of observations for how much quality improved? Or am I going to be stuck looking at the difference in means?

  • 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-18T22:41:07+00:00Added an answer on May 18, 2026 at 10:41 pm

    Maybe this is what you want: you want to display a smoothed curve of Index vs Value for “before” the transformation and for “after” the transformation, on the same graph so you can visualize the general “improvement” in quality: I show this below with some simulated data.

    bef <- .2 + 2*((1:1000)/1000 - .5)^2  + round(rnorm(1000),1)/100
    aft <- bef * (1 + rnorm(1,.7,.2))
    bef.samp <- sample(1:1000, 100)
    aft.samp <- sample(1:1000, 60)
    bef.df <- data.frame( value = bef[ bef.samp ], index = bef.samp )
    aft.df <- data.frame( value = aft[ aft.samp ], index = aft.samp )
    bef.aft <- rbind( cbind(when = 'bef', bef.df), cbind( when = 'aft', aft.df))
    ggplot(bef.aft, aes(index,value)) + 
       geom_smooth(aes(colour = when), se=0, size=1) + 
          geom_point(aes(colour=when))
    

    alt text

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

Sidebar

Related Questions

I have some data that won't printf.... echo works, but not printf There is
I have some large vectors, the data of them are coming from some calculations
I have some data. I want to go through that data and change cells
I have some data that I want to store somewhere in my Rails app
I have a big fat query that's written dynamically to integrate some data. Basically
We have some views and stored procedures which have some data hard-coded in their
I have created a user defined type to contain some data that I will
I have some data with messed-up accented characters. For example in the data we
I have some data grouped in a table by a certain criteria, and for
I have some data of the form Key ID Link 1 MASTER 123 2

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.