Question: The function add is not being rendered.
The text inside the function add not appearing when the button in the render method is clicked.
Feel this is one of those issues with what 'this' is bound too, what do y'all think?

```
import {Button, StyleSheet, Text, View } from 'react-native'

import React from 'react'

export default class App extends React.Component
{
    constructor() {
        super()
    }

    add () {
      return(
        <Text>Hi</Text>
    )}

    render(){
      return(
        <View styles={styles.button}>
            <Text> Set Timer </Text>
            <Button onPress={this.add} title="Hey there"/>
        </View>
      )
    }

}

const styles = StyleSheet.create({
  button: {
    width: 10,
    height: 10,
  }

});

```

Answer: 
To fit data to a particular model in `geom_smooth`, you can use `nls`. For example, to fit to `y ~ a + b * log(x)` you could do:

```
ggplot(data=RawData, aes(x=`Time`, y=`Curing`, col=Grade)) +
  geom_point(aes(color = Grade), shape = 1, size = 2.5) + 
  geom_smooth(method = nls, formula = y ~ a + b * log(x + 0.1),
              method.args = list(start = list(a = 1, b = 10)), se = F) + 
  scale_color_manual(values=c('#f92410','#644196')) +
  xlab("Tempo espresso in ore") + 
  ylab("% Di reticolazione") + 
  labs(color='') + 
  theme(legend.justification = "top") +
  geom_rug(aes(color = Grade))

```

[![enter image description here](https://i.stack.imgur.com/vkbc1.png)](https://i.stack.imgur.com/vkbc1.png)

However, for these particular data, one seems to get a nice curve with `y ~ a * atan(b * x)`. This is also guaranteed to go through the point [0, 0], which seems like it might be required by your model.

```r
ggplot(data=RawData, aes(x=`Time`, y=`Curing`, col=Grade)) +
  geom_point(aes(color = Grade), shape = 1, size = 2.5) + 
  geom_smooth(method = nls, formula = y ~ a * atan(b * x),
              method.args = list(start = list(a = 10, b = 5)), se = F) + 
  scale_color_manual(values=c('#f92410','#644196')) +
  xlab("Tempo espresso in ore") + 
  ylab("% Di reticolazione") + 
  labs(color='') + 
  theme(legend.justification = "top") +
  geom_rug(aes(color = Grade))

```

[![enter image description here](https://i.stack.imgur.com/wzFWB.png)](https://i.stack.imgur.com/wzFWB.png)
If your function is bound by a 100% upper limit, you could reflect that by using a logistic regression curve:

```
ggplot(data=RawData, aes(x=`Time`, y=`Curing`/100, col=Grade)) + 
  geom_point(aes(color = Grade), shape = 1, size = 2.5) + 
  geom_smooth(method = "glm", method.args = list(family = "binomial"), se = FALSE) +
  scale_y_continuous(labels = scales::percent_format()) +
  ...

```

[![enter image description here](https://i.stack.imgur.com/ozLrq.png)](https://i.stack.imgur.com/ozLrq.png)